-
Notifications
You must be signed in to change notification settings - Fork 42k
Fix Azure node's internal IP address #71736
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
Conversation
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: feiskyer 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 |
|
/assign @khenidak @andyzhangx |
aixeshunter
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
|
I doubt the issue is related to empty check removed below: Also consider the comment there: /lgtm |
There's no metadata response code check before, hence that may happen because calling of metadata service may be failed. PR #70353 adds the metadata response code checking, so I think it shouldn't be happening again. However, if that's still the case, current logic should report errors if the IP is empty. |
Only use the first IP address got from instance metadata. This is because Azure CNI would setup a list of IP addresses in instance metata, while only the first one is the Node's IP.
|
/lgtm |
|
/retest |
| } | ||
| } | ||
|
|
||
| if len(addresses) == 1 { |
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.
a little confused about the number, why it's 1 not 0, more comments here?
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.
Hostname is already included above
|
/retest Review the full test history for this PR. Silence the bot with an |
…36-upstream-release-1.11 Automated cherry pick of #71736: Fix Azure node's internal IP address
…36-upstream-release-1.12 Automated cherry pick of #71736: Fix Azure node's internal IP address
…36-upstream-release-1.13 Automated cherry pick of #71736: Fix Azure node's internal IP address
…36-upstream-release-1.10 Automated cherry pick of #71736: Fix Azure node's internal IP address
What type of PR is this?
What this PR does / why we need it:
Only use the first IP address got from instance metadata. This is because Azure CNI would set up a list of IP addresses in instance metadata, while only the first one is the Node's IP.
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Need cherry pick to 1.10-1.13.
Does this PR introduce a user-facing change?:
/sig azure
/priority critial-urgent