-
Notifications
You must be signed in to change notification settings - Fork 213
OCPBUGS-73929: lib/resourcemerge/core: Reconcile ConfigMap binaryData too #1294
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
OCPBUGS-73929: lib/resourcemerge/core: Reconcile ConfigMap binaryData too #1294
Conversation
|
@wking: This pull request references Jira Issue OCPBUGS-73929, which is valid. The bug has been moved to the POST state. 3 validation(s) were run on this bug
Requesting review from QA contact: The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
WalkthroughAdded merging of ConfigMap BinaryData: a new helper merges byte-slice maps and EnsureConfigMap now invokes it to incorporate BinaryData before merging Data. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes ✨ Finishing touches
🧹 Recent nitpick comments
📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro Cache: Disabled due to data retention organization setting Knowledge base: Disabled due to 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (1)
🧰 Additional context used📓 Path-based instructions (1)**⚙️ CodeRabbit configuration file
Files:
✏️ Tip: You can disable this entire section by setting Comment |
Since 4.20, some Cluster-API ConfigMap manifests have wanted to set this: $ oc adm release extract --to manifests quay.io/openshift-release-dev/ocp-release:4.20.10-x86_64 $ grep -r binaryData manifests manifests/0000_30_cluster-api_04_cm.infrastructure-aws.yaml:binaryData: so we need to compare the in-cluster ConfigMap with this property as well, when deciding if the resource needs updating.
2c87f33 to
d294e8c
Compare
JoelSpeed
left a comment
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.
/lgtm
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: JoelSpeed, wking The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
Seems straightforward enough that I don't think we need to wait on pre-merge verification, and I can verify post-merge: /verified by @wking |
|
@wking: This PR has been marked as verified by DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
$ oc -n openshift-cluster-api get -o jsonpath-as-json='{.binaryData.components\-zstd}' configmap aws | cut -b -80
[
"KLUv/QRolCYC2g+iWDOgaoxqDt6xwE7Zvyk57mwiafsazqcoDN8KhhZ3P5BbAujrQ8ApDwHPgX1
]Inject my own stuff: $ echo testing | base64
dGVzdGluZwo=
$ oc -n openshift-cluster-api patch configmap aws --type json -p '[{"op": "add", "path": "/binaryData/components-zstd", "value": "dGVzdGluZwo="}]'
configmap/aws patchedSee if the CVO stomped it back. Not yet... $ oc -n openshift-cluster-version logs -l k8s-app=cluster-version-operator --tail -1 | grep 'configmap.*cluster-api\|Result of work' | tail -n3
I0116 19:05:48.465959 1 task_graph.go:564] Result of work: errs=[]
I0116 19:09:32.898192 1 task_graph.go:564] Result of work: errs=[]
I0116 19:13:17.442367 1 task_graph.go:564] Result of work: errs=[]
$ oc -n openshift-cluster-api get -o jsonpath-as-json='{.binaryData.components\-zstd}' configmap aws | cut -b -80
[
"dGVzdGluZwo="
]Wait for the CVO to get through another round of reconciliation... and there's the expected stomp: $ oc -n openshift-cluster-version logs -l k8s-app=cluster-version-operator --tail -1 | grep -i 'openshift-cluster-api/aws\|Result of work' | tail -n3
I0116 19:13:17.442367 1 task_graph.go:564] Result of work: errs=[]
I0116 19:17:00.760830 1 core.go:138] Updating ConfigMap openshift-cluster-api/aws due to diff: &v1.ConfigMap{
I0116 19:17:02.027428 1 task_graph.go:564] Result of work: errs=[]
$ oc -n openshift-cluster-api get -o jsonpath-as-json='{.binaryData.components\-zstd}' configmap aws | cut -b -80
[
"KLUv/QRolCYC2g+iWDOgaoxqDt6xwE7Zvyk57mwiafsazqcoDN8KhhZ3P5BbAujrQ8ApDwHPgX1
]Looks good to me :) |
|
@wking: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
|
@wking: Jira Issue Verification Checks: Jira Issue OCPBUGS-73929 Jira Issue OCPBUGS-73929 has been moved to the MODIFIED state and will move to the VERIFIED state when the change is available in an accepted nightly payload. 🕓 DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
/cherry-pick release-4.21 release-4.20 |
|
@damdo: new pull request created: #1295 DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Since 4.20, some Cluster-API ConfigMap manifests have wanted to set this:
so we need to compare the in-cluster ConfigMap with this property as well, when deciding if the resource needs updating.