New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add md5 hash config annotation to helm check #1111
Conversation
} | ||
|
||
f.configAnnotationValue = hash | ||
f.configAnnotationKey = fmt.Sprintf("checksum/%s-config", feature.HelmCheckIDType) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add a new const for the helm check config annotation key? There's the MD5ChecksumAnnotationKey = "checksum/%s-custom-config"
const, but it's more for custom configs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That const is used for CC feature already and don't see problem using it here
datadog-operator/controllers/datadogagent/feature/clusterchecks/feature.go
Lines 267 to 268 in 36c4c4a
f.customConfigAnnotationValue = hash | |
f.customConfigAnnotationKey = object.GetChecksumAnnotationKey(feature.ClusterChecksIDType) |
* Add md5 hash for config changes * Apply review suggestions (cherry picked from commit e0fa00d)
What does this PR do?
Add md5 hash annotation to helm check configMap and cluster agent pod template spec for helm check config changes.
Motivation
QA #1060
Helm check config changes were not being taken into account by the cluster agent/CCR and the cluster agent and CCR pods were not restarting after config changes.
Additional Notes
Anything else we should know when reviewing?
Minimum Agent Versions
Are there minimum versions of the Datadog Agent and/or Cluster Agent required?
Describe your test plan
QA steps for #1060 +
datadog-helm-check-config
configmap should have the annotationchecksum/helm_check-custom-config: <md5_hash>
helmCheck.enabled
: e.ghelmCheck.collectEvents: true
tohelmCheck.collectEvents: false
orhelmCheck.valuesAsTags: {"image.tag": "image_tag", "image.repository": "image_repo"}
tohelmCheck.valuesAsTags: {"image.tag": "image_tag"}
Checklist
bug
,enhancement
,refactoring
,documentation
,tooling
, and/ordependencies
qa/skip-qa
label