cloud-init and ipv6

I started a project where I deploy one golden template with cloud-init installed and then clone the template for my VM's.

It seems the FreeBSD renderer for networking in cloud-init doesn't support IPv6 at all. I've looked at the code, and it just looks for 'static' interfaces, it doesn't deal with 'static6' interfaces at all.
I can patch it and hope it gets accepted upstream, but I'm curious, is this really the state of cloud-init on FreeBSD?
 
cloud-init minimally supports FreeBSD. You will also have problems with nameservers(v6), IP aliases and secondary interfaces and so on ;-)
For this reason, in CBSD where FreeBSD cloud images are widely used, I apply some local patches as a workaround to get IPv6 working (but I don't have the strength to fix it in upstream). Maybe this initiative will help: https://scratchpad.pkgbase.live/XZtaQUk-ToSsnaIpnQa6tQ . Also, a netlink subsystem has recently been added to FreeBSD. Probably we will get ip(8) instead of ifconfig(8) soon and will reduce the difference in the cloud-init code between Linux/FreeBSD ;-)
 
I patched cloud-init and it seems to support what I need. I basically need ip addresses, grow disks and routing. The rest can be done with ansible, either when deploying the template, or after the new VM is booted.

I’ll see if what I have gets merged upstream
 

Support for static IPv6 and setting uid got merged, now just waiting for next release
 
Back
Top