Remove deprecated one-shot scripts and update first-boot configuration for improved provisioning</message>

<message>Delete obsolete one-shot scripts for setting screen rotation and wallpaper, as well as related Python and shell scripts. Update the first-boot configuration to streamline the provisioning process by removing references to these scripts. This cleanup enhances maintainability and focuses on the essential steps required for the first boot experience, ensuring a more efficient setup for users.
This commit is contained in:
nearxos
2026-02-23 16:15:47 +02:00
parent 2d6e5aa009
commit 25bf710c67
51 changed files with 650 additions and 1192 deletions

View File

@@ -1,70 +1,46 @@
# 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.
# first-boot.conf — REQUIRED by first-boot.sh
# Copy to first-boot.conf and edit. Loaded from (first found):
# 1. same directory as first-boot.sh
# 2. /tmp/first-boot.conf (cloud-init runcmd downloads it)
# 3. /etc/cm4-provisioning/first-boot.conf
# 4. /var/lib/cm4-provisioning/first-boot.conf (persisted for phase 2)
# --- 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"
FILE_SERVER="http://10.20.50.1:5000/files/first-boot"
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"
PI_USER="pi"
# --- 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"
PACKAGES="git chromium wmctrl openssh-server swaybg wlr-randr maliit-keyboard xinput-calibrator python3-gi python3-gi-cairo"
# --- Desktop & theme ---
# LightDM session (rpd-labwc for Wayland + labwc).
# LIGHTDM_SESSION="rpd-labwc"
LIGHTDM_SESSION="rpd-labwc"
GTK_THEME_NAME="PiXnoir"
WALLPAPER_MODE="crop"
# 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"
# --- Paths ---
PLYMOUTH_DIR="/usr/share/plymouth/themes/custom"
WALLPAPER_PATH="/usr/share/rpd-wallpaper/splash.png"
# --- Display (reTerminal DM) ---
# Kernel cmdline: DSI rotation. 90 = 90° clockwise; 180 or 270 for other orientations.
# At login, ~/.config/kanshi/config is written with this transform (same as Control Center).
# DSI_ROTATE="270"
# Kernel cmdline: swiotlb size (for vc4-drm/DSI). Leave empty to skip.
# SWIOTLB_SIZE="65536"
DSI_ROTATE="270"
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"
RETERMINAL_DEVICE="reTerminal-DM"
RETERMINAL_REPO_URL="https://github.com/Seeed-Studio/seeed-linux-dtoverlays"
# --- One-shots ---
# Space-separated names of one-shot scripts to install from FILE_SERVER (each name gets name.sh + name.desktop).
# Use numbered names so they run in order at first login. Leave empty for none.
# Example: "01-set-rotation-once 02-set-wallpaper-once"
# ONESHOT_SCRIPTS="01-set-rotation-once 02-set-wallpaper-once"
# Space-separated names of one-shot scripts (each needs name.sh + name.desktop on file server).
# Leave empty for none.
ONESHOT_SCRIPTS=""
# --- Step enable flags (1 = run, 0 = skip). All steps enabled by default. Set ENABLE_STEP_NN=0 to disable. ---
# 01=hostname, 02=packages, 03=kiosk_files, 04=splash_wallpaper, 05=lightdm, 06=maliit,
# 07=dark_theme, 08=reterminal_drivers, 09=reapply_splash, 10=cmdline, 11=oneshots, 12=log_permissions, 13=reboot
# Example: uncomment to disable a step
# --- Step enable flags (1 = run, 0 = skip) ---
# Phase 1 (cloud-init → reboot): 01=hostname, 02=packages, 03=reterminal_drivers
# Phase 2 (after reboot → reboot): 04=kiosk_files, 05=splash_wallpaper, 06=lightdm,
# 07=maliit, 08=dark_theme, 09=reapply_splash, 10=cmdline, 11=oneshots,
# 12=log_permissions, 13=reboot
# ENABLE_STEP_08=0
# ENABLE_STEP_13=0