containers / initoverlayfs

GNU General Public License v2.0
35 stars 9 forks source link

Automatically upgrade initoverlayfs on kernel upgrade #66

Closed ericcurtin closed 4 months ago

ericcurtin commented 4 months ago

With this script we automatically rebuild initoverlayfs on kernel upgrade.

dougsland commented 4 months ago

@ericcurtin should we use --force?

from CI/CD:

+ /bin/bash -c 'dracut -M -o "initoverlayfs fcoe" '
dracut: Will not override existing initramfs (/boot/initramfs-6.7.3-200.fc39.x86_64.img) without --force
+ exit_code=1
+ '[' 1 '!=' 0 ']'
+ echo -n 'initoverlayfs-install completeted with 1'
initoverlayfs-install completeted with 1+ exit 1
Shared connection to 52.15.190.138 closed.
ericcurtin commented 4 months ago

@dougsland fixing

The new way of rebuilding initoverlayfs is via:

initoverlayfs-install -f

like

dracut -f

I'm finding it easier to integrate with osbuild and other tools (rpm-ostree should be easier also) to just use a dracut-like interface.

ericcurtin commented 4 months ago

Here's an example, it's not working yet, but I'm getting osbuild to do this:

subprocess.CalledProcessError: Command '['/usr/sbin/chroot', '/run/osbuild/tree', '/usr/bin/initoverlayfs-install', '--no-hostonly', '--kver', '5.14.0-416.369.el9iv.x86_64', '--force', '-v', '--show-modules', '--no-early-microcode', '--reproducible']' returned non-zero exit status 1.