diff options
author | Wesley Wiedenmeier <wesley.wiedenmeier@gmail.com> | 2016-03-18 14:41:44 -0500 |
---|---|---|
committer | Wesley Wiedenmeier <wesley.wiedenmeier@gmail.com> | 2016-03-18 14:41:44 -0500 |
commit | bb9cb8df25eaeca8740f5e1bcbc9cd2feafcba24 (patch) | |
tree | af6b30d76fbd182ee9193f9eb15206b1d5d7290e /cloudinit | |
parent | 266717afcc01c9ae2f9b4e8cfc2db08aad83de97 (diff) | |
download | vyos-cloud-init-bb9cb8df25eaeca8740f5e1bcbc9cd2feafcba24.tar.gz vyos-cloud-init-bb9cb8df25eaeca8740f5e1bcbc9cd2feafcba24.zip |
Added comments
Diffstat (limited to 'cloudinit')
-rw-r--r-- | cloudinit/net/__init__.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/cloudinit/net/__init__.py b/cloudinit/net/__init__.py index 88d0061c..e2dcaee7 100644 --- a/cloudinit/net/__init__.py +++ b/cloudinit/net/__init__.py @@ -282,7 +282,9 @@ def parse_net_config(path): def load_klibc_net_cfg(data_mapping): """Process key value pairs from files written because of the ip parameter - on the kernel cmdline""" + on the kernel cmdline, note that mode: manual is used because the + interface should already have been brought up by the kernel and + cloud-initramfs-tools""" entry_ns = { 'mtu': None, 'name': data_mapping['DEVICE'], 'type': 'physical', 'mode': 'manual', 'inet': 'inet', 'gateway': None, 'address': None, @@ -304,6 +306,8 @@ def load_klibc_net_cfg(data_mapping): if data_mapping.get('IPV6ADDR'): entry_ns['subnets'].append({'type': 'dhcp6'}) elif data_mapping.get('PROTO') in ['static', 'none']: + # It appears that specifying ipv6 static addrs does not work, so only + # check for ipv4 addr entry_ns['subnets'].append( {'type': 'static', 'address': data_mapping.get('IPV4ADDR')}) |