New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dracut initramfs boot #1191
base: main
Are you sure you want to change the base?
Dracut initramfs boot #1191
Conversation
@JasonYangShadow I refactored our work here, squashing redundant commits and making sure everything had a clear progression and commit messages. Let me know what you think. |
a8f9330
to
570e72f
Compare
75c70fe
to
1efd185
Compare
Rebased on main. |
8f7ce29
to
a7ff590
Compare
a54d8c5
to
f6950ef
Compare
The initramfs stage supports serving an initramfs image from within the container image, typically generated by dracut. Signed-off-by: xu yang <xyang@ciq.com> Signed-off-by: Jonathon Anderson <janderson@ciq.com>
warewulf-dracut includes a dracut module to be installed in a container image to support building an initramfs that can boot from Warewulf. Signed-off-by: Jonathon Anderson <janderson@ciq.com>
dracut.ipxe boots an initramfs detected in the container image. This required a few small changes to warewulfd and the wwinit overlay to accommodate the dracut initramfs configuring the network interface before wwinit: - Include .NetDevs in the ipxe configuration template, so that dracut can configure interfaces with the correct names. - Configure NetworkManager to not keep the initramfs configuration, in stead applying the configuration found by wwinit. Signed-off-by: Jonathon Anderson <janderson@ciq.com>
Signed-off-by: Jonathon Anderson <janderson@ciq.com>
Signed-off-by: Jonathon Anderson <janderson@ciq.com>
initramfs uses tmpfs regardless of whether root=tmpfs in Warewulf. As such, 90-selinux needs to be updated to detect the actual provenance of /, rather than the configured setting. Signed-off-by: Jonathon Anderson <janderson@ciq.com>
f6950ef
to
8fb7543
Compare
If we link this together with #815 we have state full install. Steps for this would be:
This would allow a dump of the container to the rootfs. What is till missing would be checks, if the rootfs needs to be updated or reinstalled. I think this could achieved by placing configurations in |
then | ||
info "Loading ${archive}" | ||
(curl --silent -L "${archive}" | gzip -d | cpio -im --directory="${NEWROOT}") || die "Unable to load ${archive}" | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
die
isn't a posix shell function, so (echo "Unable to load ${archive}";exit 1)
should do the same.
@anderbubble my commit is WIP, some args get lost |
I think the problem here is that |
had to add a new package containerrun which gathers all functions which run or build a container in order to avoid circular depencies Signed-off-by: Christian Goll <cgoll@suse.com>
37dc34f
to
e9eb232
Compare
@anderbubble @JasonYangShadow Buidling the dracut works now on |
Description of the Pull Request (PR):
Support booting a dracut image from a container and using it to bootstrap a large container.
To-do
This fixes or addresses the following GitHub issues:
Before submitting a PR, make sure you have done the following:
git commit --signoff
) in agreement to the DCO