-
Notifications
You must be signed in to change notification settings - Fork 47
[OSPRH-12359] Fix getting IPSets #574
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
[OSPRH-12359] Fix getting IPSets #574
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: vyzigold The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Turns out IPSets use the node's hostname as defined in the nodeset CR, not the node's name. These 2 might be the same, but they might differ and in case they differ, the controller doesn't find them and it uses the ansible inventory secret to get the IPs instead. Unfortunatelly the hostname from the nodeset isn't always copied into the ansible inventory secret. It either gets copied into the canonical_hostname variable as is or a DNS domain is appended to it, so I introduced a bit of code to pick the correct parts of the canonical_hostname. This worked for both cases described above when I tested it, there is also still the fallback to using the ansibleHost from the inventory secret.
/retest |
5 similar comments
/retest |
/retest |
/retest |
/retest |
/retest |
/lgtm |
23ac41a
into
openstack-k8s-operators:main
/cherry-pick 18.0-fr1 |
@vyzigold: new pull request created: #590 In 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. |
Turns out IPSets use the node's hostname as defined in the nodeset CR, not the node's name. These 2 might be the same, but they might differ and in case they differ, the controller doesn't find them and it uses the ansible inventory secret to get the IPs instead.
Unfortunatelly the hostname from the nodeset isn't always copied into the ansible inventory secret. It either gets copied into the canonical_hostname variable as is or a DNS domain is appended to it, so I introduced a bit of code to pick the correct parts of the canonical_hostname.
This worked for both cases described above when I tested it, there is also still the fallback to using the ansibleHost from the inventory secret.