This repository contains the material used for the presentation "From Containerfile
to Virtual Machine". It describes the use of bootc (bootable containers), which uses a Containerfile
to create a container and converts this to a (virtual) machine.
The source of the presentation is available in the presentation
directory. The presentation is written in Markdown (revealjs) and uses Obsidian's Extended Slides plugin.
An export is available at https://gbraad-redhat.github.io/fedora-bootc-example/
The container
directory contains the Containerfile
, which is build using the workflow scripts in .github/workflows
.
Runs of these actions can be found at https://github.com/gbraad-redhat/fedora-bootc-example/actions
Successful builds are available at https://github.com/orgs/gbraad-redhat/packages?repo_name=fedora-bootc-example.
The latest disk image is available at https://github.com/gbraad-redhat/fedora-bootc-example/releases/tag/latest, which is purposely a release behind the container builds. Therefore you can use sudo bootc update
to update the disk image to the latest version.
This file is named disk.qcow2
and can be run with:
$ sudo virt-install \
--name fedora-bootc --os-variant fedora-eln \
--cpu host --vcpus 2 --memory 2048 \
--import --disk disk.qcow2
After the machine came up, you can log in using:
$ ssh admin@<ip>
Note
The password is password
.
The bootc-based container images are pushed to a 'public' registry, while the disk image is released as a GitHub release.
After an update to the container image, you push to the registry and update the running VM using bootc update
.
@gbraad |