~chad.smith/cloud-init:bug/1800223-retry-imds-on-timeout

Last commit made on 2018-11-12
Get this branch:
git clone -b bug/1800223-retry-imds-on-timeout https://git.launchpad.net/~chad.smith/cloud-init
Only Chad Smith can upload to this branch. If you are Chad Smith please log in for upload directions.

Branch merges

Branch information

Name:
bug/1800223-retry-imds-on-timeout
Repository:
lp:~chad.smith/cloud-init

Recent commits

ac9305f... by Chad Smith

proper UrlError unittest setup

2db73eb... by Chad Smith

drop optional UrlError params from unittest

1c4016b... by Chad Smith

drop optional UrlError params from unittest

0a48fca... by Chad Smith

add retry_on_url_exc function to url_helper for use in readurl

df194b2... by Chad Smith

azure: retry imds polling on requests.Timeout

There is an infrequent race when the booting instance can hit the IMDS
service before it is fully available. This results in a
requests.ConnectTimeout being raised.
Azure's retry_callback logic now retries on either 404s or Timeouts.

LP:1800223

d910ecd... by Aswin Rajamannar

azure: fix regression introduced when persisting ephemeral dhcp lease

In commitish 9073951 azure datasource tried to leverage stale DHCP
information obtained from EphemeralDHCPv4 context manager to report
updated provisioning status to the fabric earlier in the boot process.

Unfortunately the stale ephemeral network configuration had already been
torn down in preparation to bring up IMDS network config so the report
attempt failed on timeout.

This branch introduces obtain_lease and clean_network public methods on
EphemeralDHCPv4 to allow for setup and teardown of ephemeral network
configuration without using a context manager. Azure datasource now uses
this to persist ephemeral network configuration across multiple contexts
during provisioning to avoid multiple DHCP roundtrips.

3b332c9... by Chad Smith

azure: add udev rules to create cloud-init Gen2 disk name symlinks

Cloud-init delivers udev rules on Azure to create the following symlinks:
- /dev/disk/cloud/azure_root
- /dev/disk/cloud/azure_root-part#
- /dev/disk/cloud/azure_resource
- /dev/disk/cloud/azure_resource-part#

Cloud-init cc_disk_setup expects presence of these dev links in order to
setup the mounted ephemeral disks. Gen1 instances udev rules match based
only a DEVICE_ID attribute that no longer exists on Gen2 instances.
Supplement existing Gen1 rules with matches on specitic SCSI target/lun
path 0:0:0 and 0:0:1 and generate links for azure_root and azure_resource
respectively.

LP: #1797480

093f968... by Chad Smith

tests: ec2 mock missing httpretty user-data and instance-identity routes

58476e7... by Chad Smith

azure: remove /etc/netplan/90-hotplug-azure.yaml when net from IMDS

There was a typo in the seeded filename s/azure-hotplug/hotplug-azure/.

9073951... by Aswin Rajamannar

azure: report ready to fabric after reprovision and reduce logging

When reusing a preprovisioned VM, report ready to Azure fabric as soon as
we get the reprovision data and the goal state so that we are not delayed
by the cloud-init stage switch, saving 2-3 seconds. Also reduce logging
when polling IMDS for reprovision data.

LP: #1799594