Bug 238068 - OpenStack Image with cloud-init support?
Summary: OpenStack Image with cloud-init support?
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: 12.0-RELEASE
Hardware: amd64 Any
: --- Affects Some People
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-23 09:23 UTC by rainer
Modified: 2019-06-05 14:35 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description rainer 2019-05-23 09:23:16 UTC
Hi,

it seems that the qcow2 image of FreeBSD 12.0 does not contain cloud-init support.

There is a PR here:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=213396

that adds it, but it doesn't seem to go anywhere.
On top of that, it didn't really work for me.

There are Openstack-ready images for Ubuntu, Fedora, CentOS - basically almost everything.

Is there a reason that the FreeBSD project does not provide one?
Comment 1 olevole 2019-05-23 09:35:47 UTC
cloud-init does not work on FreeBSD (as a localStorage data source) at the moment. There are many open PR related to FreeBSD at https://git.launchpad.net/cloud-init ( I also opened several ). So, if you can't fix it yourself, you just need to wait.

For example, the latest release of cloud-init has some improvements for FreeBSD (fixes for detect cidata media), and I am creating my own FreeBSD cloud image for the CBSD project[1][2] . But there are some quick hacks ( to apply parameters ) on my part that will never go upstream ( since I did a quick work-around not in cloud-init code )

__
[1] ZFS: https://github.com/cbsd/cbsd/blob/develop/etc/defaults/vm-freebsd-cloud-FreeBSD-zfs-x64-12.0.conf
[2] UFS: https://github.com/cbsd/cbsd/blob/develop/etc/defaults/vm-freebsd-cloud-FreeBSD-ufs-x64-12.0.conf
Comment 2 rainer 2019-05-23 10:53:56 UTC
Hi,

thanks for the update.

I did however now succeed using the official Openstack documentation:

https://docs.openstack.org/image-guide/freebsd-image.html

(using qemu-kvm on my local OpenSuSE workstation to create the image).

cloud-init runs, creates the freebsd-user and I can login.
The partition is also grown.

For now, this is enough for me.

cloud-init requires several python modules and sudo, 43 packages all together.
The RAM-disk created by the installer seems to be just about enough to allow these packages to be downloaded and installed.

I realize that it's the FreeBSD project's intention not to pollute the installation-image with anything that is not in tree.

But increasingly, FreeBSD will be installed virtually and users in the cloud expect certain things to "just work".