summaryrefslogtreecommitdiff
path: root/cloudinit/analyze/__main__.py
diff options
context:
space:
mode:
authorScott Moser <smoser@brickies.net>2017-11-20 15:56:40 -0500
committerScott Moser <smoser@brickies.net>2017-11-20 15:56:40 -0500
commit281a82181716183d526e76f4e0415e0a6f680cbe (patch)
treecf617a96b41289112787dcef23b358bf5e63c8f9 /cloudinit/analyze/__main__.py
parentd3a0958c09c73a78fda6e922b749a1b98036e984 (diff)
downloadvyos-cloud-init-281a82181716183d526e76f4e0415e0a6f680cbe.tar.gz
vyos-cloud-init-281a82181716183d526e76f4e0415e0a6f680cbe.zip
EC2: Fix bug using fallback_nic and metadata when restoring from cache.
If user upgraded to new cloud-init and attempted to run 'cloud-init init' without rebooting, cloud-init restores the datasource object from pickle. The older version pickled datasource object had no value for _network_config or fallback_nic. This caused the Ec2 datasource to attempt to reconfigure networking with a None fallback_nic. The pickled object also cached an older version of ec2 metadata which didn't contain network information. This branch does two things: - Add a fallback_interface property to DatasourceEC2 to support reading the old .fallback_nic attribute if it was set. New versions will call net.find_fallback_nic() if there has not been one found. - Re-crawl metadata if we are on Ec2 and don't have a 'network' key in metadata LP: #1732917
Diffstat (limited to 'cloudinit/analyze/__main__.py')
0 files changed, 0 insertions, 0 deletions