fix: enhance IP address validation to include global unicast check #3084
fix: enhance IP address validation to include global unicast check #3084kubesphere-prow[bot] merged 1 commit intokubesphere:mainfrom
Conversation
…r IPv4 and IPv6 Signed-off-by: redscholar <[email protected]>
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: redscholar 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 |
|
There was a problem hiding this comment.
Code Review
This pull request refines the IP address selection logic in pkg/variable/variable_get.go by incorporating IsGlobalUnicast() checks for both IPv4 and IPv6 addresses. These changes ensure that only routable addresses are selected, filtering out link-local addresses that are unsuitable for cluster communication. I have no additional feedback to provide as the existing review comments were purely evaluative and did not identify any issues or further improvements.



What type of PR is this?
/kind bug
What this PR does / why we need it:
etcd and kubelet need global or ula ip.
Which issue(s) this PR fixes:
Fixes #
Special notes for reviewers:
Does this PR introduced a user-facing change?
Additional documentation, usage docs, etc.: