Skip to content

A custom controller for kubernetes to dynamically propagate config maps

Notifications You must be signed in to change notification settings

Toha-K-M/DynamicConfigMapPropagator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Video Demo: https://asciinema.org/a/8oRlcN3eumfXZcgEkbKClyqFw

examples are in kube-example folder

Dynamic ConfigMap Propagator

Create Operator

Init Operator

operator-sdk init --domain custom --repo DynamicConfigMapPropagator

Update Makefile

Update makefile for accessing the controller-gen, set the following to Makefile

CONTROLLER_GEN ?= $(GOBIN)/controller-gen

Create API

Create ConfigMapSyncer Api.

operator-sdk create api --group syncer --version v1alpha1 --kind ConfigMapSyncer --resource --controller --namespaced=true

Modify Operator

Update Api

Deploy

Make Manifests and Generator

make manifests

make generate

Docker Build and Push

make docker-build docker-push

Deploy to Kubernetes

kubectl apply -f kube/crds/
kubectl apply -f kube/manifests/namespace.yaml

kubectl apply -f kube/manifests/rbac.yaml

kubectl apply -f kube/manifests/controller.yaml

Apply Custom Resource

kubectl apply -f kube/custom-resource/configmapsyncer.yaml

Test Operator

kubectl apply -f kube/configmaps/master-cm-one.yaml

kubectl apply -f kube/configmaps/random-cm.yaml

About

A custom controller for kubernetes to dynamically propagate config maps

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published