From 43053f94cdef47ce10c1782ff18238a72cc36524 Mon Sep 17 00:00:00 2001 From: Joseph Marrero Corchado Date: Thu, 9 Jan 2025 10:59:15 -0500 Subject: [PATCH] baseimage: Add systemd configuration files Added a kernel-install configuration that enables the rpm-ostree integration. The second configuration file sets the Journal to persistent as on bootc systems /var is empty by default and systemd by default enables persistent journaling on the presence of /var/log/journal. Signed-off-by: Joseph Marrero --- Makefile | 3 +++ baseimage/README.md | 2 ++ baseimage/systemd/usr/lib/kernel/install.conf | 5 +++++ 3 files changed, 10 insertions(+) create mode 100644 baseimage/systemd/usr/lib/kernel/install.conf diff --git a/Makefile b/Makefile index 156591dcd..3809c4b93 100644 --- a/Makefile +++ b/Makefile @@ -32,7 +32,10 @@ install: cp -PfT baseimage/base/ostree $(DESTDIR)/$(prefix)/share/doc/bootc/baseimage/base/ostree # Ensure we've cleaned out any possibly older files rm -vrf $(DESTDIR)$(prefix)/share/doc/bootc/baseimage/dracut + rm -vrf $(DESTDIR)$(prefix)/share/doc/bootc/baseimage/systemd + # Copy dracut and systemd config files cp -Prf baseimage/dracut $(DESTDIR)$(prefix)/share/doc/bootc/baseimage/dracut + cp -Prf baseimage/systemd $(DESTDIR)$(prefix)/share/doc/bootc/baseimage/systemd # Run this to also take over the functionality of `ostree container` for example. # Only needed for OS/distros that have callers invoking `ostree container` and not bootc. diff --git a/baseimage/README.md b/baseimage/README.md index 510ca8577..51dc2de6d 100644 --- a/baseimage/README.md +++ b/baseimage/README.md @@ -10,3 +10,5 @@ sources of content. may go away in the future) and the `ostree` symlink into `sysroot`. - [dracut](dracut): Default/basic dracut configuration; at the current time this basically just enables ostree in the initramfs. +- [systemd](systemd): Optional configuration for systemd, currently + this has configuration for kernel-install enabling rpm-ostree integration. diff --git a/baseimage/systemd/usr/lib/kernel/install.conf b/baseimage/systemd/usr/lib/kernel/install.conf new file mode 100644 index 000000000..4acaefb07 --- /dev/null +++ b/baseimage/systemd/usr/lib/kernel/install.conf @@ -0,0 +1,5 @@ +# kernel-install will not try to run dracut and allow rpm-ostree to +# take over. Rpm-ostree will use this to know that it is responsible +# to run dracut and ensure that there is only one kernel in the image +layout=ostree +