aws-load-balancer-controller icon indicating copy to clipboard operation
aws-load-balancer-controller copied to clipboard

Query IMDS over IPv6 if no IPv4 interface address

Open johngmyers opened this issue 3 years ago • 4 comments

Issue

Description

Queries IMDS over IPv6 if there is no non-loopback IPv4 interface address.

Checklist

  • [ ] Added tests that cover your change (if possible)
  • [ ] Added/modified documentation as required (such as the README.md, or the docs directory)
  • [x] Manually tested
  • [x] Made sure the title of the PR is a good description that can go into the release notes

BONUS POINTS checklist: complete for good vibes and maybe prizes?! :exploding_head:

  • [ ] Backfilled missing tests for code in same general area :tada:
  • [x] Refactored something and made the world a better place :star2:

johngmyers avatar Jan 10 '22 06:01 johngmyers

Codecov Report

Base: 54.12% // Head: 54.12% // No change to project coverage :thumbsup:

Coverage data is based on head (3c8839c) compared to base (b20f899). Patch has no changes to coverable lines.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2453   +/-   ##
=======================================
  Coverage   54.12%   54.12%           
=======================================
  Files         144      144           
  Lines        8268     8268           
=======================================
  Hits         4475     4475           
  Misses       3469     3469           
  Partials      324      324           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

codecov-commenter avatar Jan 10 '22 06:01 codecov-commenter

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot avatar Aug 05 '22 06:08 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot avatar Sep 04 '22 06:09 k8s-triage-robot

/remove-lifecycle rotten

johngmyers avatar Sep 10 '22 02:09 johngmyers

/lgtm

olemarkus avatar Oct 01 '22 19:10 olemarkus

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: johngmyers, kishorj, olemarkus

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 /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

k8s-ci-robot avatar Oct 01 '22 19:10 k8s-ci-robot

to be honest, i still don't think we should do this from the controller. It should be AWSSDK-GO to automatically detect IMDS if necessary.

And this detection feels hacky to me as well, e.g. you might have IMDS only available in ipv6 but the container have some other ipv4 addresses as well(e.g. cni's dummy ipv4 addresses for ipv6 only mode). Would be better to follow AWSSDK's practice to have the explicitly configure knob before AWSSDK have automatic detection mechanism.

M00nF1sh avatar Oct 05 '22 22:10 M00nF1sh

I would also prefer this be done in AWSSDK-GO, but aws-sdk has stated, without any explanation or discussion, that they are not going to do that. So this would need to be done client-by-client. The PR aws/aws-sdk-go#4234 has gotten no attention in months.

The container having non-loopback IPv4 addresses is an obscure corner case and is not negatively impacted by this change. Such unusual situations can still be handled by setting the environment variable.

johngmyers avatar Oct 05 '22 23:10 johngmyers