How and where is the cloud-init datasource configured on the libre lepotato ubuntu images?

Hi @librecomputer I’ve been unable to figure out how the cloud-init data source is configured.

How and where is the the cloud-init data source configured on ubuntu images?

I would like to modify the image so that the cloud-init data source points to a http server on my network.

Board: lepotato
Image: Ubuntu server image
Ubuntu cloud-init doc for nocloud datasource: NoCloud - cloud-init 22.4.2 documentation

Places I’ve looked:

  1. /boot/grub/grub.cfg for a ds= kernel command-line parameter
  2. SMBIOS serial number (using ‘sudo dmidecode’. All serial numbers are “Serial Number: Not specified” for System, Base Board, Chassis)
  3. Filesystems labels on all partitions. Bot blkid and dosfslabel both return ‘system-boot’ as the label for /dev/mmcblk1p1 partition, which is the vfat EFI partition. Ubuntu docs say that file system label has to be cidata or CIDATA.

Question: How and where is the the cloud-init data source configured on ubuntu images?
Answer: /etc/cloud/cloud.cfg.d/99-fake_cloud.cfg and /run/cloud-init/cloud.cfg

Got there by looking the cloud-init log file located at /run/cloud-init/ds-identify.log

PS: Obviously the datasource was configured in the least-documented place. :slight_smile: :slight_smile: At least it isn’t a customized cloud-init binary :).

Relevant doc I missed earlier: Configuration sources - cloud-init 22.4.2 documentation

Am having fun wading through this low-level stuff – brings back memories of poking around with DOS boot sectors and stuff. :slight_smile:

Keep up the work!