diskimage-builder/diskimage_builder/elements/cloud-init-datasources/README.rst
Julia Kreger e544379010 ConfigDrive: Disable cloud-init auto dhcp by default
If your using configuration drive, cloud init tries to DHCP by
default anyway, which delays the boot sequence as it seeks out a
network attached metadata source.

So instead, disable the automatic activation so the configuration
drive data source is acutally leverage. Additionally add further
notes to provide guidance to users of DIB.

Change-Id: Ie7c522f23deb3f08ee4ec002e0e2020f382359aa
2024-04-29 18:39:41 +00:00

1.3 KiB

cloud-init-datasources

Configures cloud-init to only use an explicit list of data sources.

Cloud-init contains a growing collection of data source modules and most are enabled by default. This causes cloud-init to query each data source on first boot. This can cause delays or even boot problems depending on your environment.

Including this element without setting DIB_CLOUD_INIT_DATASOURCES will cause image builds to fail.

Environment Variables

DIB_CLOUD_INIT_DATASOURCES
Required

Yes

Default

None

Description

A comma-separated list of valid data sources to limit the data sources that will be queried for metadata on first boot.

Example

DIB_CLOUD_INIT_DATASOURCES="Ec2" will enable only the Ec2 data source.

Example

DIB_CLOUD_INIT_DATASOURCES="Ec2, ConfigDrive, OpenStack" will enable the Ec2, ConfigDrive and OpenStack data sources.

Warning

Use of the ConfigDrive data source is only considered, by default, for initial network configuration per cloud-init documentation. It is recommended that you utilize OpenStack in addition to ConfigDrive to collect all available metadata and configuration. As a result of configuration drive use, cloud-init's automatic metadata discovery network activation is disabled.