You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Produce Fedora and RHEL “boxes” that can be used with Vagrant [1], more specifically with vagrant-libvirt provider [2]. This means it won’t be usable with any other provider, namely Docker, Hyper-V, VMWare, or VirtualBox. In the future we might want to support at least VirtualBox to enable people running macOS to take advantage of this feature.
In the following text, whenever I refer to a “vagrant box” I mean a libvirt specific one.
Scope of the work
Vagrant box is a tarball containing [3]
qcow2 image
image.json - file containing very little amount of metadata (example here)
default Vagrantfile - default configuration of the box (example here)
Both files can be static and thus it is not necessary to store them directly in the pipeline.
I think the work can be divided into two parts:
Create the qcow2 image with required configuration [4]
Create the tarball.
Creation of the image
According to the documentation [4], the base image must contain a running SSH server. Additionally, it must contain a specific user with a specific SSH key and it should use a well-known root password. All of this is possible with current osbuild and osbuild-composer implementation.
It is also required to have a specific sudo configuration and sshd configuration. This would require changing a configuration file, therefore it is related to the work from Will about how to handle cases like this. [5][6]
Creation of the tarball
This part is more complicated and cannot be achieved with current osbuild implementation. It basically requires an “assembler pipeline” where we produce qcow2 image and then take the produced image and create a tarball containing it. The metadata files will be mostly or completely predefined (I think completely, but I’m not 100% sure).
We can leave this part out and use a shell script to generate a tarball out of a qcow2 image.
Proposed steps
Create a pipeline (json file) and metadata by hand (json and Vagrantfile), verify that it can work. This pipeline will contain script stages to configure sudo and sshd.
Create “vagrant-libvirt” output type here (osbuild-composer) containing all the customizations required
Implement vagrant-libvirt assembler in osbuild (this can copy & paste our current qemu assembler and add a tar call at the end)
Finish the work in osbuild-composer by using the new osbuild feature
Final note (for Open Source Contest)
It is not necessary to implement all the steps. In fact it is way to much for a single contribution, so feel free to implement only parts of it (e.g. only create the pipeline, or only implement the stages)
Goals
Produce Fedora and RHEL “boxes” that can be used with Vagrant [1], more specifically with vagrant-libvirt provider [2]. This means it won’t be usable with any other provider, namely Docker, Hyper-V, VMWare, or VirtualBox. In the future we might want to support at least VirtualBox to enable people running macOS to take advantage of this feature.
In the following text, whenever I refer to a “vagrant box” I mean a libvirt specific one.
Scope of the work
Vagrant box is a tarball containing [3]
Both files can be static and thus it is not necessary to store them directly in the pipeline.
I think the work can be divided into two parts:
Creation of the image
According to the documentation [4], the base image must contain a running SSH server. Additionally, it must contain a specific user with a specific SSH key and it should use a well-known root password. All of this is possible with current osbuild and osbuild-composer implementation.
It is also required to have a specific sudo configuration and sshd configuration. This would require changing a configuration file, therefore it is related to the work from Will about how to handle cases like this. [5][6]
Creation of the tarball
This part is more complicated and cannot be achieved with current osbuild implementation. It basically requires an “assembler pipeline” where we produce qcow2 image and then take the produced image and create a tarball containing it. The metadata files will be mostly or completely predefined (I think completely, but I’m not 100% sure).
We can leave this part out and use a shell script to generate a tarball out of a qcow2 image.
Proposed steps
tar
call at the end)Final note (for Open Source Contest)
It is not necessary to implement all the steps. In fact it is way to much for a single contribution, so feel free to implement only parts of it (e.g. only create the pipeline, or only implement the stages)
Sources
[1] https://www.vagrantup.com/
[2] https://github.com/vagrant-libvirt/vagrant-libvirt
[3] https://github.com/vagrant-libvirt/vagrant-libvirt/tree/master/example_box
[4] https://www.vagrantup.com/docs/boxes/base.html#creating-a-base-box-1
[5] osbuild/osbuild#181
[6] osbuild/osbuild#191
The text was updated successfully, but these errors were encountered: