Skip to content

About

A repo, that doesn't take itself too seriously. A repo for messaging around with Bootable Container (aka Image Mode)

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

Image Mode Shenanigans

Bootable Fedora kiosk OS, built with bootc, published as both a GHCR image and a bootable ISO.

Why This Repo Exists

This project turns a single repo into a reproducible kiosk platform:

  • Builds a bootable OS image from Containerfile.
  • Publishes OCI tags to GHCR (latest and commit SHA).
  • Produces an installable ISO via bootc-image-builder.
  • Boots into GNOME Kiosk, autologs user kiosk, and opens Chromium in kiosk mode.
  • Injects a break-glass admin user at ISO build time from GitHub Actions secrets.
  • Includes flightctl-agent, configured from repo-managed config-files/flightctl/config.yaml.

System Overview

flowchart LR
  A["Push to main"] --> B["GitHub Actions"]
  B --> C["Build bootc image"]
  C --> D["Push to GHCR"]
  D --> E["bootc-image-builder"]
  E --> F["ISO artifact"]
  F --> G["Install on VM or hardware"]
  G --> H["GDM autologin (kiosk)"]
  H --> I["GNOME Kiosk session"]
  I --> J["Chromium --kiosk http://127.0.0.1/"]
Loading

Repo Map

  • Containerfile: Bootable OS definition.
  • .github/workflows/image-build.yml: Build + publish + ISO pipeline.
  • bootc/config.toml: bootc-image-builder customization baseline.
  • bootc/build.toml: Helper metadata for image/build paths.
  • config-files/gdm-custom.conf: GNOME Display Manager autologin + default session config.
  • config-files/gnome-kiosk-script: Script entrypoint used by gnome-kiosk-script-session.
  • config-files/kiosk-chromium.sh: Chromium kiosk launch loop.
  • config-files/dconf-00-kiosk: GNOME lock/suspend/power defaults.
  • config-files/kiosk-script-home-link.conf: Ensures the kiosk script is available at ~/.local/bin/gnome-kiosk-script.
  • config-files/org.gnome.Tour.desktop: Disables GNOME Tour first-run prompt.
  • config-files/gnome-keyring-*.desktop: Disables keyring agent autostarts to avoid password prompts.
  • config-files/kiosk-nginx.container: Quadlet container definition for local content.
  • config-files/environment: Editable system-wide /etc/environment proxy template (HTTP/HTTPS/NO_PROXY).
  • config-files/kiosk-pos-agent.py: Local scanner/receipt bridge API (127.0.0.1:8091).
  • config-files/kiosk-pos.conf: Editable POS runtime configuration copied to /etc/kiosk-pos.conf.
  • config-files/kiosk-zebra.conf: Zebra installer settings copied to /etc/kiosk-zebra.conf.
  • config-files/kiosk-install-zebra.sh: Local RPM installer script used at image build time for CoreScanner.
  • config-files/kiosk-pos-agent.service: Boot service that exposes scan events and print endpoint.
  • config-files/flightctl/config.yaml: Authoritative flightctl-agent config copied to /etc/flightctl/config.yaml.
  • config-files/flightctl/10-config-path.conf: Systemd drop-in that forces flightctl-agent to use /etc/flightctl/config.yaml.
  • Zebra/: Local Zebra RPM payload staged into the image at /usr/local/share/zebra.
  • index.html: Kiosk web UI/content.
  • screensaver.mp4: Idle screensaver video shown after inactivity.

How To Consume What It Builds

1. Use the Generated ISO (Fastest Path)

  1. Open the latest successful run of Build, Push, and Build bootc ISO.
  2. Download artifact bootc-iso-<sha>.
  3. Boot a VM or machine from that ISO.
  4. Install and reboot.

Expected post-install behavior:

  • No manual GNOME login prompt.
  • Chromium opens in kiosk mode automatically.
  • break-glass user exists and is in wheel.

2. Use the Published GHCR Image

IMAGE_REF="ghcr.io/<owner>/<repo>:latest"
mkdir -p output
sudo podman pull "$IMAGE_REF"

sudo podman run --rm --privileged \
  --security-opt label=type:unconfined_t \
  -v "$(pwd)/output:/output" \
  -v /var/lib/containers/storage:/var/lib/containers/storage \
  quay.io/centos-bootc/bootc-image-builder:latest \
  --type anaconda-iso \
  --rootfs xfs \
  "$IMAGE_REF"

Clone It And Make Your Own

git clone https://github.com/<your-org-or-user>/image-mode-shenanigans.git
cd image-mode-shenanigans

Then customize in this order:

  1. Edit kiosk content in index.html.
  2. Edit browser behavior in config-files/kiosk-chromium.sh.
  3. Adjust login/session defaults in config-files/gdm-custom.conf.
  4. Adjust GNOME Kiosk script handoff in config-files/gnome-kiosk-script.
  5. Adjust GNOME lock/power defaults in config-files/dconf-00-kiosk.
  6. Adjust first-run/keyring suppression in config-files/org.gnome.Tour.desktop and config-files/gnome-keyring-*.desktop.
  7. Adjust bootc disk sizing in bootc/config.toml.
  8. Update your image reference in bootc/build.toml.
  9. Push to main to trigger image + ISO builds.

GitHub Actions Requirements

Workflow file: .github/workflows/image-build.yml

Required secrets:

  • BREAK_GLASS_PASSWORD
  • BREAK_GLASS_SSH_PUBLIC_KEY

What CI does:

  1. Builds/pushes image to ghcr.io/<owner>/<repo>.
  2. Stamps index.html with UI build metadata: Build <run-number> • <short-sha>.
  3. Copies bootc/config.toml into a temporary config.
  4. Appends:
[[customizations.user]]
name = "break-glass"
password = "<from-secret>"
key = "<from-secret>"
groups = ["wheel"]
  1. Builds ISO with --config /config.toml.
  2. Uploads ISO artifacts.

Flightctl Configuration

flightctl-agent is installed in the base image and enabled at boot.

Source of truth:

  • config-files/flightctl/config.yaml

Image paths:

  • /etc/flightctl/config.yaml
  • /etc/systemd/system/flightctl-agent.service.d/10-config-path.conf

Security note:

  • This repository intentionally stores flightctl enrollment/certificate material in git. Treat repository access as sensitive and rotate credentials on exposure.

Troubleshooting

  • Zebra/CoreScanner install verification:
rpm -qa | grep -i zebra
systemctl status cscore.service || systemctl status corescanner.service
  • POS bridge service status:
sudo systemctl status kiosk-pos-agent.service
curl -I http://127.0.0.1:8091/healthz
  • flightctl agent status:
sudo systemctl status flightctl-agent.service
journalctl -u flightctl-agent -b --no-pager | tail -n 100
  • POS config edit points:
sudoedit /etc/kiosk-pos.conf
sudoedit /etc/kiosk-zebra.conf
sudo systemctl restart kiosk-pos-agent.service
  • GNOME still shows login screen:
sudo systemctl status gdm
sudo cat /etc/gdm/custom.conf
  • Chromium does not launch:
cat /var/home/kiosk/kiosk-session.log
  • Kiosk page not reachable:
sudo systemctl status kiosk-nginx.service
curl -I http://127.0.0.1/

Notes

  • This repo is intentionally image-first: you version the OS behavior and app content together.
  • break-glass is created during ISO build customization, not hardcoded into the base image layer.
  • Screensaver behavior is browser-managed in index.html with a 60-second inactivity timer.
  • For best kiosk playback reliability, screensaver.mp4 should use H.264 video + AAC audio in an MP4 container.

About

A repo, that doesn't take itself too seriously. A repo for messaging around with Bootable Container (aka Image Mode)

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages