Skip to content

Conversation

@djhouseknecht
Copy link

Issue

At some point in the recent past, the /latest/meta-data/.../ipv4-associations/{private-ip} endpoint started bunching up all public IPs to one private IP. In the AWS console, the public IPs were still mapped to the correct private IPs. This bug/feature from the endpoint caused the mappings to break since aws-eni thought that only one private IP had a public IP assigned even though multiple private IPs could have had public IPs associated.

Resolution

Instead of hitting /meta-data/... endpoints to query for public IPs, this PR will start using aws ec2 describe-addresses to fetch the actual private/public IP mappings for a given ENI.

raise Errors::MetaBadResponse unless Meta.interface(hwaddr, '', not_found: nil)
{
hwaddr: hwaddr,
instance_id: Meta.instance('instance-id'),
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was easier to just add this to the info's metadata than trying to pull it from lib/aws-eni.rb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant