Hi.
I am trying to move my network settings out of the containers (I have custom vlan setup) to organize it in the profiles that I have instead. However cloud-init does not seam to work for some reason.
I have flashed a fresh install of Ubuntu Server 22.04 to a test server where I have tried both LXD 5.0.1 and the latest 5.6. I have tried creating containers from ubuntu:22.04
and images:ubuntu/22.04/cloud
, but nothing works. I have also tried using cloud-init.network-config
as stated here: cloud-init - LXD documentation as well as user.network-config
as stated here: Custom network configuration with cloud-init - LXD documentation. But nothing is changed at all.
I tried using some of the other options, just to see if I could get something to work:
config:
cloud-init.user-data: |
runcmd:
- [touch, /cloud.init.ran]
But this fails as well. No file is created.
The only way to affect the network from a profile, was to create a mount from the host to /etc/netplan on the container, with a yaml file. This works, but I would much rather have cloud-init work properly.