-
Notifications
You must be signed in to change notification settings - Fork 102
Fix: Trigger nodeSet reconciler with ansibleVarsFrom changes #1766
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
Fix: Trigger nodeSet reconciler with ansibleVarsFrom changes #1766
Conversation
363aa04 to
041c79f
Compare
|
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/2f91f3518f594651aa31a353d4524c5a ❌ openstack-k8s-operators-content-provider FAILURE in 5m 19s |
slagle
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.
this looks good. I can test it in my environment as well.
|
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/50b1d132f5ab43838db660d50fa0e335 ✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 56m 28s |
test/kuttl/tests/dataplane-deploy-no-nodes-test/08-ansiblevars-deploy.yaml
Show resolved
Hide resolved
|
/retest-required |
test/kuttl/tests/dataplane-deploy-no-nodes-test/08-ansiblevars-deploy.yaml
Show resolved
Hide resolved
|
Can you also squash some of the smaller commits into other commits? Or, add more detail to each commits message. It just help with keeping a cleaner git history when this is merged. |
e662eec to
e19f49a
Compare
The NodeSet reconciler was not being triggered when ConfigMaps and Secrets referenced in ansibleVarsFrom were modified. This caused the NodeSet status to not update when configuration data changed, preventing deployments from recognizing that nodes redeployment. Changes: - Add ProcessAnsibleVarsFrom function in internal/dataplane/hashes.go to compute hashes for ConfigMaps and Secrets referenced in AnsibleVarsFrom at both NodeTemplate and individual Node - Add checkAnsibleVarsFromChanged function in the NodeSet controller to compare current hashes with deployed hashes and detect configuration drift. - Update deployment controller with setNodeSetAnsibleVarsFromHashes to store ConfigMap and Secret hashes in deployment status for comparison - Add kuttl test cases to verify ansibleVarsFrom change detection triggers proper reconciliation (08-ansiblevars-deploy and 09-ansiblevars-update) The fix ensures that when a ConfigMap or Secret referenced by ansibleVarsFrom is modified, the NodeSet controller detects the change and updates its status to indicate it is no longer ready for deployment, allowing operators to trigger a new deployment with the updated configuration. Jira: OSPRH-17961 Co-Authored-By: Claude <noreply@anthropic.com>
e19f49a to
3292252
Compare
|
Build failed (check pipeline). Post https://softwarefactory-project.io/zuul/t/rdoproject.org/buildset/e111fad9ecd349bfaee7f9fdf6553019 ✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 10m 33s |
|
recheck |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: oliashish, slagle 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 |
The NodeSet reconciler would not triggered on changes to ConfigMaps and Secrets from ansibleVarsFrom as we never check them and it won't update the NodeSet status and message to mark it ready for deployment
Jira: OSPRH-17961