From: Jeff Layton <jlayton@kernel.org>
To: kdevops@lists.linux.dev
Subject: [PATCH] guestfs: eliminate rescue initramfs images from base images
Date: Wed, 24 Sep 2025 16:16:50 -0400 [thread overview]
Message-ID: <20250924201650.333989-1-jlayton@kernel.org> (raw)
dracut-config-rescue generates the "rescue" images in the /boot
partition (at least on Fedora hosts). This is a waste of space since
these are ultimately throwaway VMs.
Uninstall dracut-config-rescue from the base images so that rescue
initrds are not generated in the guests, thus saving space for more
"make linux" invocations.
Signed-off-by: Jeff Layton <jlayton@kernel.org>
---
playbooks/roles/base_image/templates/virt-builder.j2 | 2 ++
1 file changed, 2 insertions(+)
diff --git a/playbooks/roles/base_image/templates/virt-builder.j2 b/playbooks/roles/base_image/templates/virt-builder.j2
index 6805679a8959..3f927f516c4b 100644
--- a/playbooks/roles/base_image/templates/virt-builder.j2
+++ b/playbooks/roles/base_image/templates/virt-builder.j2
@@ -13,6 +13,8 @@ copy-in {{ guestfs_distro_source_and_dest_file }}:{{ target_dir }}
{% endif %}
install sudo,qemu-guest-agent,python3,bash
+uninstall dracut-config-rescue
+
run-command useradd {{ kdevops_uid }} -s /bin/bash -m kdevops
append-line /etc/sudoers.d/kdevops:kdevops ALL=(ALL) NOPASSWD: ALL
edit /etc/default/grub:s/^GRUB_CMDLINE_LINUX_DEFAULT=.*/GRUB_CMDLINE_LINUX_DEFAULT="console=ttyS0"/
--
2.51.0
reply other threads:[~2025-09-24 20:16 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250924201650.333989-1-jlayton@kernel.org \
--to=jlayton@kernel.org \
--cc=kdevops@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox