Refactor first-boot process to introduce ordered execution and new one-shot scripts
Revise the first-boot script to implement a structured approach with 13 numbered steps, allowing for better control over the execution order. Introduce two new one-shot scripts: `01-set-rotation-once.sh` and `02-set-wallpaper-once.sh`, replacing the previous single script approach. Update documentation to reflect these changes, including the new configuration options for enabling/disabling steps and the revised file structure for one-shot scripts. Enhance the dashboard to display first-boot progress, improving user feedback during the initial setup.
This commit is contained in:
60
emmc-provisioning/cloud-init/first-boot.conf
Normal file
60
emmc-provisioning/cloud-init/first-boot.conf
Normal file
@@ -0,0 +1,60 @@
|
||||
# first-boot.conf.example
|
||||
# Copy to first-boot.conf and edit. Loaded by first-boot.sh from:
|
||||
# - same directory as first-boot.sh, or
|
||||
# - /tmp/first-boot.conf (when run via cloud-init), or
|
||||
# - /etc/cm4-provisioning/first-boot.conf
|
||||
# Unset variables keep the script's built-in defaults.
|
||||
|
||||
# --- File server & host ---
|
||||
# Base URL for first-boot assets (scripts, splash, configs). No trailing slash.
|
||||
FILE_SERVER="http://10.20.50.1:5000/files/first-boot"
|
||||
|
||||
# Hostname set on the device.
|
||||
HOSTNAME="guard"
|
||||
|
||||
# --- User ---
|
||||
# Login user (must exist; cloud-init user-data must create the same user).
|
||||
PI_USER="pi"
|
||||
|
||||
# --- Paths (optional overrides) ---
|
||||
# First-boot log file.
|
||||
LOGFILE="/var/log/first-boot.log"
|
||||
|
||||
# Plymouth custom theme directory.
|
||||
PLYMOUTH_DIR="/usr/share/plymouth/themes/custom"
|
||||
|
||||
# Wallpaper path (splash.png is also copied here).
|
||||
WALLPAPER_PATH="/usr/share/rpd-wallpaper/splash.png"
|
||||
|
||||
# --- Packages ---
|
||||
# Space-separated list of packages to install. Must include: git chromium wmctrl openssh-server
|
||||
# swaybg wlr-randr maliit-keyboard xinput-calibrator (for kiosk + labwc + touch).
|
||||
PACKAGES="git chromium wmctrl openssh-server swaybg wlr-randr maliit-keyboard xinput-calibrator"
|
||||
|
||||
# --- Desktop & theme ---
|
||||
# LightDM session (rpd-labwc for Wayland + labwc).
|
||||
LIGHTDM_SESSION="rpd-labwc"
|
||||
|
||||
# GTK dark theme name (e.g. PiXnoir; fallback is Adwaita-dark if missing).
|
||||
GTK_THEME_NAME="PiXnoir"
|
||||
|
||||
# Wallpaper mode for pcmanfm (crop, stretch, fit, center, tile, screen, color).
|
||||
WALLPAPER_MODE="crop"
|
||||
|
||||
# --- Display (reTerminal DM) ---
|
||||
# Kernel cmdline: DSI rotation. 90 = 90° clockwise; use 180 or 270 for other orientations.
|
||||
DSI_ROTATE="270"
|
||||
|
||||
# Kernel cmdline: swiotlb size (for vc4-drm/DSI). Leave empty to skip.
|
||||
SWIOTLB_SIZE="65536"
|
||||
|
||||
# --- reTerminal (Seeed) ---
|
||||
# Device passed to reTerminal.sh (reTerminal-DM for reTerminal DM).
|
||||
RETERMINAL_DEVICE="reTerminal-DM"
|
||||
|
||||
# Seeed overlays repo (clone URL). Leave empty to skip driver install.
|
||||
RETERMINAL_REPO_URL="https://github.com/Seeed-Studio/seeed-linux-dtoverlays"
|
||||
|
||||
# --- One-shots ---
|
||||
# Space-separated names of one-shot scripts (numbered = run order at first login). Leave empty for none.
|
||||
ONESHOT_SCRIPTS="01-set-rotation-once 02-set-wallpaper-once"
|
||||
Reference in New Issue
Block a user