fix(codeapi-chart): make package PVC argo-safe#7
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this fixes
This PR fixes the CodeAPI package-cache PVC behavior under Argo CD.
codeapi-packagesnow renders as a normal retained PVC with Argo sync wave-10.codeapi-package-initnow renders as an ArgoSynchook with sync wave-5.Why
Argo CD maps
helm.sh/hook: pre-install,pre-upgradeto aPreSynchook. Hook resources default toBeforeHookCreationdelete behavior when no Argo delete policy is present. A persistent PVC must not be a hook resource because Argo can try to delete and recreate it during sync.This came up during the CodeAPI staging rollout: the old chart marked
codeapi-packagesas a Helm hook, and Argo attempted to delete it during an image-only sync.Branch coverage
maincdacbc6helm/codeapi/templates/pvc.yamlhelm/codeapi/templates/package-init-job.yamlhelm/codeapi/values.yamlVerification
Current head:
git diff --check-> passedhelm dependency build helm/codeapi-> passedhelm template codeapi helm/codeapi -n codeapi -f /private/tmp/df-cloud-codeapi-stg-rollout/helm-charts/codeapi/stg/values.yaml-> passedargocd.argoproj.io/sync-wave: "-10"and nohelm.sh/hook; package init Job hasargocd.argoproj.io/hook: Sync, sync wave-5, andBeforeHookCreation,HookSucceededSecurity / privacy
No secrets or private values are included in this PR. The rendered staging verification checked annotations and resource shape only.
Blocking before merge
None. GitHub checks passed on PR #7.
Follow-up after merge