Smaller image: fewer kernel modules and files, unused services removed, oomd for jobs
- Kernel modules: all but hardware drivers, plus the VM and podman network drivers. - Removed: System.map, the udev hwdb, and the homed/userdbd/nsresourced units. - Job image: no translations (Locale=C.UTF-8). - systemd-oomd kills the job container that runs the VM out of memory. - gitea-runner waits for first-boot setup instead of restarting every 10s. - Tighter comments in the sysctl config; Verify=no explained in the transfers. /usr: 367 -> 307 MB, update download 317 -> 260 MB. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01V27snrGfdvwU7pMNBiDpHv
This commit is contained in:
9 files changed
+64
-21
No files matched your search
+31
@@ -68,3 +68,34 @@ KernelInitrdModules=
|
||||
dm-verity
|
||||
erofs
|
||||
ext4
|
||||
# Kernel modules in the image: all but the hardware drivers, then the drivers of a VM (disks,
|
||||
# network, screen) and of podman's networks. The last matching line wins. Keyboard, USB and a
|
||||
# basic screen are built into the kernel.
|
||||
KernelModules=
|
||||
/*
|
||||
-/drivers/*
|
||||
/drivers/virtio/*
|
||||
/drivers/block/*
|
||||
/drivers/md/*
|
||||
nvme
|
||||
virtio_scsi
|
||||
sd_mod
|
||||
virtio_net
|
||||
qemu_fw_cfg
|
||||
bochs
|
||||
virtio-gpu
|
||||
veth
|
||||
tun
|
||||
macvlan
|
||||
ipvlan
|
||||
# - System.map only for debugging the kernel
|
||||
# - udev hwdb hardware names and quirks, nothing a VM needs
|
||||
# - homed, userdbd, nsresourced unused services; removing their units also stops them
|
||||
# on hosts installed before (/etc keeps them enabled)
|
||||
RemoveFiles=
|
||||
/usr/lib/modules/*/System.map
|
||||
/usr/lib/udev/hwdb.bin
|
||||
/usr/lib/udev/hwdb.d
|
||||
/usr/lib/systemd/system/systemd-homed*
|
||||
/usr/lib/systemd/system/systemd-userdbd.*
|
||||
/usr/lib/systemd/system/systemd-nsresourced.*
|
||||
Reference in new issue
Block a user