Page MenuHomeFreeBSD

enable cloud-init on FreeBSD for Azure
ClosedPublic

Authored by honzhan_microsoft.com on May 2 2017, 6:33 AM.

Details

Summary

cloud-init official version does not support FreeBSD on Azure, the merge request (https://code.launchpad.net/~redriver/cloud-init/+git/cloud-init/+merge/314895) is still pending for review.
In order not to block the usage on Azure, this ports target to patch on cloud-init 0.7.9 to make it work for FreeBSD 10.3/11 on Azure.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

add the missing build for cloud-init-azure

I can't see the rc script is it installed by setup.py?
I don't think the pkg-message is needed, it is just the usual way to activate a service

net/cloud-init-azure/Makefile
17 ↗(On Diff #27955)

Why is it depending on sudo? I bet cloudinit is run as root isn't it?

46 ↗(On Diff #27955)

usually this is a ; not &&

This revision is now accepted and ready to land.May 3 2017, 9:00 AM
bapt requested changes to this revision.May 6 2017, 12:27 PM

So after looking at the content of the package:
it installs plenty of rc.d/*.orig files that should be removed

The cloudinit_override function is all wrong and should just be removed

All configuration files in /etc are wrong they should be in /usr/local/etc

The NetworkManager hook should just not be installed we do not support networkmanager on freebsd

The libudev rules has no sense on freebsd

/etc/dhcp/dhclient-exit-hooks.d/hook-dhclient is also not valid on freebsd

This revision now requires changes to proceed.May 6 2017, 12:27 PM
In D10566#220480, @bapt wrote:

So after looking at the content of the package:
it installs plenty of rc.d/*.orig files that should be removed

The cloudinit_override function is all wrong and should just be removed

The NetworkManager hook should just not be installed we do not support networkmanager on freebsd

The libudev rules has no sense on freebsd

/etc/dhcp/dhclient-exit-hooks.d/hook-dhclient is also not valid on freebsd

All above have been revised.

All configuration files in /etc are wrong they should be in /usr/local/etc

cloud-init default finds the configuration file from '/etc/cloud', and it is hard coded in settings.py. It is not easy to change this in a short term. Shall we leave it there now?

net/cloud-init-azure/Makefile
17 ↗(On Diff #27955)

Yes, I will remove this dependence.

This revision was automatically updated to reflect the committed changes.