canonical / canonical/cloud-init

ec2: add support for rendering public IP addresses in network config

Open
#3,622 0 comments 0 reactions 0 assignees View on GitHub
bug ds: ec2 launchpad
Dominant language
Python
Stars
3.8k
Forks
1.1k
Avg merge
3d 8h
Merged PRs (30d)
22

Description

This bug was originally filed in Launchpad as [LP: #1867197](https://bugs.launchpad.net/cloud-init/+bug/1867197)

Launchpad details

affected_projects = []

assignee = None
assignee_name = None
date_closed = None
date_created = 2020-03-12T19:14:52.711395+00:00
date_fix_committed = None
date_fix_released = None
id = 1867197
importance = medium
is_complete = False
lp_url = https://bugs.launchpad.net/cloud-init/+bug/1867197
milestone = None
owner = chad.smith
owner_name = Chad Smith
private = False
status = triaged
submitter = chad.smith
submitter_name = Chad Smith
tags = []
duplicates = []

_Launchpad user **Chad Smith(chad.smith)** wrote on 2020-03-12T19:14:52.711395+00:00_

cloud-init 20.1 currently renders only local ip address information in the network configuration emitted for attached NICs.

Ec2 instances can be launched and configured with multiple public IP addresses

https://aws.amazon.com/blogs/aws/multiple-ip-addresses-for-ec2-instances-in-a-virtual-private-cloud/

Ec2 IMDS network data exposes public IPv4 addresses in the following metadata keys:
* network.interfaces.macs..public-ipv4s = "18.218.219.181"
* and an association of public ip to the private IPs allocated via the key
"ipv4-associations": {
 "18.218.219.181": "172.31.44.13"
 },

Cloud-init should render known public ipv4 address configuration on the node to avoid network round trips for local services that may connect with the VMs known public IP

Contributor guide

Open the contributing guide

Research direction

No files or tests are named. Start by tracing the EC2 IMDS network metadata for public-ipv4s and ipv4-associations into the network configuration renderer; done when known public IPv4 addresses are emitted for attached NICs without requiring network round trips.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, python
Domain
cloud, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.