feat: add deployment-metadata configmap to trigger pod restarts on git changes

This commit is contained in:
Unchained
2026-03-07 11:01:04 +02:00
parent 5ce35817a1
commit ee391a7b8d
2 changed files with 17 additions and 7 deletions

View File

@@ -1,6 +1,16 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- deployment-nodejs.yaml
- service.yaml
- ingress.yaml
- deployment-nodejs.yaml
- service.yaml
- ingress.yaml
# Generate a ConfigMap with git revision info
# This ConfigMap changes on each Flux reconciliation, triggering pod restarts
configMapGenerator:
- name: deployment-metadata
literals:
- GIT_REVISION=${GIT_REVISION}
- DEPLOY_TIME=${DEPLOY_TIME}
options:
disableNameSuffixHash: false # Changing hash forces pod restart