rekonfig

module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 28, 2019 License: BSD-3-Clause

README

Rekonfig

Rekonfig monitors Deployment and ConfigMap/Secret mounted, ensures that each Deployment's Pod always have up to date configuration.

Whenever a ConfigMap or Secret is updated, Rekonfig trigger a Rolling Update of the Deployment.

Installation

To deploy Rekonfig to a Kubernetes cluster.

$ kubectl apply -f ./deploy

Configuration

Rekonfig watches all Deployment within a Kubernetes cluster but only processes those with the annotation rekonfig.gitops.in/update-on-konfig-change: "true".

As shown below, once enabled, Rekonfig will set the configuration hash as an annotation rekonfig.gitops.in/konfig-hash on the Deployment's PodTemplate.

apiVersion: apps/v1beta1
kind: StatefulSet
metadata:
  annotations:
    rekonfig.gitops.in/update-on-konfig-change: "true"
  labels:
    app: my-app
  name: my-app
  namespace: default
spec:
  replicas: 1
  selector:
    matchLabels:
      app: my-app
  serviceName: my-app-headless
  template:
    metadata:
      annotations:
        rekonfig.gitops.in/konfig-hash: "<SHA256_HASH>"
# ...

Test

$ make test

Build

$ make build

Directories

Path Synopsis
cmd
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL