Add KAMOS branding (wallpaper, logo) and easy app customization lists
- packages.list: system packages baked into the image - flatpaks.list + first-boot service: default apps, auto-installed - wallpaper stamped over stock desktop wallpapers at build time Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
8afbd4de94
commit
9fb709cdcd
8 changed files with 97 additions and 16 deletions
11
README.md
11
README.md
|
|
@ -105,8 +105,15 @@ rpm-ostree rebase ostree-unverified-registry:YOUR-FORGEJO-DOMAIN/YOUR-USERNAME/k
|
|||
|
||||
## Customizing KAMOS
|
||||
|
||||
- **Add packages baked into the OS:** edit `build_files/build.sh`
|
||||
(`dnf5 -y install <package>`), push — CI rebuilds the image.
|
||||
- **Add/remove system packages:** edit [`build_files/packages.list`](build_files/packages.list)
|
||||
— one package name per line, `#` for comments. Push, CI rebuilds.
|
||||
- **Add/remove default apps (Flatpaks):** edit
|
||||
[`system_files/usr/share/kamos/flatpaks.list`](system_files/usr/share/kamos/flatpaks.list)
|
||||
with Flathub app IDs — installed automatically on each machine's first boot.
|
||||
- **Wallpaper/logo:** replace
|
||||
`system_files/usr/share/backgrounds/kamos/kamos-default.png` and
|
||||
`system_files/usr/share/pixmaps/kamos-logo.png`. The build stamps the
|
||||
wallpaper over all stock desktop wallpapers.
|
||||
- **Add config files:** drop them under `system_files/` mirroring the target
|
||||
path (e.g. `system_files/etc/foo.conf` → `/etc/foo.conf`).
|
||||
- **Apps like Heroic, Lutris, Discord, OBS:** install as Flatpaks after boot
|
||||
|
|
|
|||
|
|
@ -11,23 +11,37 @@ sed -i 's/^NAME=.*/NAME="KAMOS"/' /usr/lib/os-release
|
|||
sed -i 's/^PRETTY_NAME=.*/PRETTY_NAME="KAMOS (Gaming Edition)"/' /usr/lib/os-release
|
||||
|
||||
### ---------------------------------------------------------------
|
||||
### 2. Extra packages layered on top of Bazzite
|
||||
### Bazzite stable already ships: Steam, Gamescope, Proton (via
|
||||
### Steam), MangoHud, vkBasalt, gamemode, Lutris deps, Waydroid,
|
||||
### Distrobox, KDE Plasma, HDR/VRR support, fsync kernel.
|
||||
### Add anything extra you want baked into the OS here.
|
||||
### 2. System packages from build_files/packages.list
|
||||
### ---------------------------------------------------------------
|
||||
dnf5 -y install \
|
||||
btop \
|
||||
fastfetch
|
||||
|
||||
# Examples (uncomment to include):
|
||||
# dnf5 -y install openrgb # RGB peripheral control
|
||||
# dnf5 -y install corectrl # AMD GPU/CPU tuning UI
|
||||
# dnf5 -y install input-remapper # remap controller/keyboard
|
||||
PKGS=$(sed -e 's/#.*//' -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' \
|
||||
/tmp/build_files/packages.list | grep -v '^$' || true)
|
||||
if [ -n "$PKGS" ]; then
|
||||
# shellcheck disable=SC2086
|
||||
dnf5 -y install $PKGS
|
||||
fi
|
||||
|
||||
### ---------------------------------------------------------------
|
||||
### 3. System defaults
|
||||
### 3. Wallpaper branding: replace every stock wallpaper image with
|
||||
### the KAMOS one so the desktop defaults to KAMOS artwork
|
||||
### ---------------------------------------------------------------
|
||||
WALL=/usr/share/backgrounds/kamos/kamos-default.png
|
||||
if [ -f "$WALL" ]; then
|
||||
find /usr/share/wallpapers /usr/share/backgrounds \
|
||||
-type f \( -name '*.png' -o -name '*.jpg' -o -name '*.jpeg' \) \
|
||||
! -path '*/kamos/*' -print0 2>/dev/null |
|
||||
while IFS= read -r -d '' img; do
|
||||
cp -f "$WALL" "$img"
|
||||
done
|
||||
fi
|
||||
|
||||
### ---------------------------------------------------------------
|
||||
### 4. First-boot Flatpak apps (list: /usr/share/kamos/flatpaks.list)
|
||||
### ---------------------------------------------------------------
|
||||
chmod +x /usr/libexec/kamos-install-flatpaks
|
||||
systemctl enable kamos-flatpaks.service
|
||||
|
||||
### ---------------------------------------------------------------
|
||||
### 5. System defaults
|
||||
### ---------------------------------------------------------------
|
||||
# Enable weekly automatic OS updates (staged, applied on reboot)
|
||||
systemctl enable rpm-ostreed-automatic.timer || true
|
||||
|
|
|
|||
11
build_files/packages.list
Normal file
11
build_files/packages.list
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
# System packages baked into the KAMOS image (one per line).
|
||||
# Add a package name to include it in the OS; delete a line to remove it.
|
||||
# Lines starting with # are ignored. Changes take effect on the next build.
|
||||
|
||||
btop
|
||||
fastfetch
|
||||
|
||||
# --- popular extras (remove the # to enable) ---
|
||||
# openrgb # RGB peripheral control
|
||||
# corectrl # AMD GPU/CPU tuning UI
|
||||
# input-remapper # remap controller/keyboard buttons
|
||||
13
system_files/usr/lib/systemd/system/kamos-flatpaks.service
Normal file
13
system_files/usr/lib/systemd/system/kamos-flatpaks.service
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
[Unit]
|
||||
Description=Install KAMOS default Flatpak apps (first boot)
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
ConditionPathExists=!/var/lib/kamos-flatpaks-done
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/libexec/kamos-install-flatpaks
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
23
system_files/usr/libexec/kamos-install-flatpaks
Normal file
23
system_files/usr/libexec/kamos-install-flatpaks
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env bash
|
||||
# Installs the default KAMOS Flatpak apps on first boot (runs once).
|
||||
set -u
|
||||
|
||||
LIST=/usr/share/kamos/flatpaks.list
|
||||
STAMP=/var/lib/kamos-flatpaks-done
|
||||
|
||||
[ -f "$STAMP" ] && exit 0
|
||||
|
||||
flatpak remote-add --if-not-exists --system flathub \
|
||||
https://dl.flathub.org/repo/flathub.flatpakrepo || true
|
||||
|
||||
ok=1
|
||||
while IFS= read -r app; do
|
||||
case "$app" in ''|\#*) continue ;; esac
|
||||
app="${app%%#*}"; app="$(echo "$app" | xargs)"
|
||||
[ -z "$app" ] && continue
|
||||
flatpak install --system --noninteractive --or-update flathub "$app" || ok=0
|
||||
done < "$LIST"
|
||||
|
||||
# Only mark done when everything succeeded, so it retries next boot otherwise
|
||||
[ "$ok" = 1 ] && touch "$STAMP"
|
||||
exit 0
|
||||
BIN
system_files/usr/share/backgrounds/kamos/kamos-default.png
Normal file
BIN
system_files/usr/share/backgrounds/kamos/kamos-default.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 311 KiB |
13
system_files/usr/share/kamos/flatpaks.list
Normal file
13
system_files/usr/share/kamos/flatpaks.list
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
# Flatpak apps KAMOS installs automatically on first boot (one per line).
|
||||
# Add a Flathub app ID to include it; delete a line to remove it from new
|
||||
# installs. Find IDs at https://flathub.org (page URL ends with the ID).
|
||||
# Lines starting with # are ignored.
|
||||
|
||||
com.heroicgameslauncher.hgl
|
||||
net.davidotek.pupgui2
|
||||
|
||||
# --- popular extras (remove the # to enable) ---
|
||||
# com.discordapp.Discord
|
||||
# com.obsproject.Studio
|
||||
# org.videolan.VLC
|
||||
# com.spotify.Client
|
||||
BIN
system_files/usr/share/pixmaps/kamos-logo.png
Normal file
BIN
system_files/usr/share/pixmaps/kamos-logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 24 KiB |
Loading…
Reference in a new issue