From 477793d581ed144a2ad919bf6cb354c26d43c019 Mon Sep 17 00:00:00 2001 From: Philip Peterson <1326208+philip-peterson@users.noreply.github.com> Date: Sat, 26 Sep 2026 01:04:59 -0800 Subject: [PATCH] Initial format --- Containerfile | 7 +++ README.md | 54 +++++++++---------- .../systemd}/journald.conf.d/size-cap.conf | 0 .../system/rpm-ostree-cleanup.service | 0 .../systemd}/system/rpm-ostree-cleanup.timer | 0 .../systemd/user-preset/90-quine-linux.preset | 1 + .../lib/systemd}/user/disk-cleanup.service | 0 .../usr/lib/systemd}/user/disk-cleanup.timer | 0 8 files changed, 34 insertions(+), 28 deletions(-) create mode 100644 Containerfile rename {systemd => overlay/etc/systemd}/journald.conf.d/size-cap.conf (100%) rename {systemd => overlay/etc/systemd}/system/rpm-ostree-cleanup.service (100%) rename {systemd => overlay/etc/systemd}/system/rpm-ostree-cleanup.timer (100%) create mode 100644 overlay/usr/lib/systemd/user-preset/90-quine-linux.preset rename {systemd => overlay/usr/lib/systemd}/user/disk-cleanup.service (100%) rename {systemd => overlay/usr/lib/systemd}/user/disk-cleanup.timer (100%) diff --git a/Containerfile b/Containerfile new file mode 100644 index 0000000..bfc9b0b --- /dev/null +++ b/Containerfile @@ -0,0 +1,7 @@ +FROM ghcr.io/ublue-os/aurora:stable + +COPY overlay/ / + +# System-level units are enabled explicitly. User units are picked up +# automatically via overlay/usr/lib/systemd/user-preset/. +RUN systemctl enable rpm-ostree-cleanup.timer diff --git a/README.md b/README.md index b1a081a..6be2cda 100644 --- a/README.md +++ b/README.md @@ -2,49 +2,47 @@ Quine distro of Linux based on uBlue Aurora -## systemd/user/disk-cleanup.{service,timer} +## Building -Weekly, runs as the user, no privilege needed: `podman system prune -af`, -`flatpak uninstall --unused -y`, clears `~/.cache`. +`Containerfile` builds a custom bootc image on top of `ghcr.io/ublue-os/aurora:stable`, +layering in everything under `overlay/`: ```sh -cp systemd/user/disk-cleanup.* ~/.config/systemd/user/ -systemctl --user daemon-reload -systemctl --user enable --now disk-cleanup.timer +podman build -t quine-linux -f Containerfile . ``` -## systemd/system/rpm-ostree-cleanup.{service,timer} - -Weekly, runs as root via systemd (not cron/sudoers): `rpm-ostree cleanup -rb` -(drops rollback deployment and any pending deployment). - -```sh -sudo cp systemd/system/rpm-ostree-cleanup.* /etc/systemd/system/ -sudo systemctl daemon-reload -sudo systemctl enable --now rpm-ostree-cleanup.timer -``` +An ISO can then be generated from the built image with `bootc-image-builder`. ## overlay/ -Files here mirror their path on the root filesystem, meant to be baked into -the image (e.g. `COPY overlay/ /` in a future Containerfile). Until then, -apply manually: +Files here mirror their path on the root filesystem and are baked into the +image via `COPY overlay/ /` in the Containerfile. -```sh -sudo cp overlay/etc/gitconfig /etc/gitconfig -``` +- `overlay/etc/...` — local/admin config. On the ostree-based image, content + shipped here becomes the default `/etc` and is still locally overridable + (3-way merged on upgrade), same as any package-installed `/etc` file. +- `overlay/usr/lib/systemd/...` — vendor-shipped units. `/usr` is replaced + wholesale on each image build/upgrade, so anything here always matches the + image and isn't meant to be hand-edited on a running system. ### overlay/etc/gitconfig System-wide git config so every user on the box gets `main` as the default init branch, not `master`. -## systemd/journald.conf.d/size-cap.conf +### overlay/etc/systemd/system/rpm-ostree-cleanup.{service,timer} + +Weekly, runs as root via systemd (not cron/sudoers): `rpm-ostree cleanup -rb` +(drops rollback deployment and any pending deployment). Enabled at build time +via `RUN systemctl enable` in the Containerfile. + +### overlay/etc/systemd/journald.conf.d/size-cap.conf Continuous 500M journal retention cap instead of a periodic vacuum job. -```sh -sudo mkdir -p /etc/systemd/journald.conf.d -sudo cp systemd/journald.conf.d/size-cap.conf /etc/systemd/journald.conf.d/ -sudo systemctl restart systemd-journald -``` +### overlay/usr/lib/systemd/user/disk-cleanup.{service,timer} + +Weekly, runs as the user, no privilege needed: `podman system prune -af`, +`flatpak uninstall --unused -y`, clears `~/.cache`. Auto-enabled for every +user via `overlay/usr/lib/systemd/user-preset/90-quine-linux.preset` — no +manual `systemctl --user enable` needed. diff --git a/systemd/journald.conf.d/size-cap.conf b/overlay/etc/systemd/journald.conf.d/size-cap.conf similarity index 100% rename from systemd/journald.conf.d/size-cap.conf rename to overlay/etc/systemd/journald.conf.d/size-cap.conf diff --git a/systemd/system/rpm-ostree-cleanup.service b/overlay/etc/systemd/system/rpm-ostree-cleanup.service similarity index 100% rename from systemd/system/rpm-ostree-cleanup.service rename to overlay/etc/systemd/system/rpm-ostree-cleanup.service diff --git a/systemd/system/rpm-ostree-cleanup.timer b/overlay/etc/systemd/system/rpm-ostree-cleanup.timer similarity index 100% rename from systemd/system/rpm-ostree-cleanup.timer rename to overlay/etc/systemd/system/rpm-ostree-cleanup.timer diff --git a/overlay/usr/lib/systemd/user-preset/90-quine-linux.preset b/overlay/usr/lib/systemd/user-preset/90-quine-linux.preset new file mode 100644 index 0000000..cb5194b --- /dev/null +++ b/overlay/usr/lib/systemd/user-preset/90-quine-linux.preset @@ -0,0 +1 @@ +enable disk-cleanup.timer diff --git a/systemd/user/disk-cleanup.service b/overlay/usr/lib/systemd/user/disk-cleanup.service similarity index 100% rename from systemd/user/disk-cleanup.service rename to overlay/usr/lib/systemd/user/disk-cleanup.service diff --git a/systemd/user/disk-cleanup.timer b/overlay/usr/lib/systemd/user/disk-cleanup.timer similarity index 100% rename from systemd/user/disk-cleanup.timer rename to overlay/usr/lib/systemd/user/disk-cleanup.timer