Getting two IPs - 10-lxc.yaml applies DHCP although 50-cloud-init.yaml is set to STATIC

Ok good to know and thank you for looking into that!

I’ve got a temporary fix in place now which is to write the following to 10-lxc.yaml:

network:
  version: 2
  ethernets:
    eth0: {dhcp4: false}

Side note: I initially set the contents of 10-lxc.yaml to be blank or just a comment, but that causes cloud-init to not setup the static IP in 50-cloud-init.yaml for some reason. Tried grep’ing the cloud-init.log / cloud-init-output.log to see why, but nothing stuck out (also not super familiar with the cloud-init process to be honest).

Regardless, my temp fix above works for now, thanks!

1 Like