Remove obsolete audio and buzzer control documentation files, including detailed guides and HTML interfaces, to streamline the repository and eliminate redundancy. This cleanup enhances maintainability and focuses on essential resources for the reTerminal DM4 audio and buzzer functionalities.

This commit is contained in:
nearxos
2026-02-20 15:39:39 +02:00
parent 9656771d5a
commit 58d9144752
101 changed files with 80 additions and 193 deletions

16
README.md Normal file
View File

@@ -0,0 +1,16 @@
# reTerminal DM4
Project for **reTerminal DM4** (Seeed) with CM4: Chromium kiosk, eMMC provisioning (USB + network boot), and first-boot configuration via cloud-init.
## Repository structure
| Path | Purpose |
|------|---------|
| **emmc-provisioning/** | **Main workflow:** eMMC deploy/backup, cloud-init first-boot, Chromium kiosk assets, file server, dashboard, network boot. See [emmc-provisioning/README.md](emmc-provisioning/README.md). |
| **archive/** | Legacy or unused files (guides, old scripts). Not used for deployment. See [archive/README.md](archive/README.md). |
## Quick start
1. Read **emmc-provisioning/docs/EMMC-PROVISIONING-GUIDE.md** for full setup.
2. Use **emmc-provisioning/scripts/sync-portal-files-to-lxc.sh** to sync first-boot assets (including kiosk) to the file server.
3. Provision devices via USB boot or network boot; first-boot configures kiosk, labwc, rotation, wallpaper, dark theme, and optional CM4 boot order.

10
archive/README.md Normal file
View File

@@ -0,0 +1,10 @@
# Archive
This folder holds files that are no longer part of the active reTerminal DM4 / eMMC provisioning workflow. Kept for reference only.
| Subfolder | Contents |
|-----------|----------|
| **chromium-setup-legacy/** | Old Chromium-setup guides and scripts: KDE installation, LED/buzzer control, audio config, touchscreen options, Flask apps, test scripts, revert-to-lxde. Kiosk assets (start-chromium.sh, chromium-kiosk.desktop) live in `emmc-provisioning/cloud-init/` and `emmc-provisioning/cloud-init/config-files/`. |
| **cloud-init-duplicates/** | Duplicate or superseded cloud-init files (e.g. plymouth-custom.script duplicate of `files-from-guard/plymouth-custom/custom.script`). |
Do not rely on archived files for deployment; use the main tree under **emmc-provisioning/**.

View File

@@ -1,147 +0,0 @@
# Chromium Auto-Start Configuration for Raspberry Pi
This directory contains scripts and configuration files to automatically start Chromium in fullscreen mode on boot for a Raspberry Pi device (reTerminal DM4).
## Files
- **`start-chromium.sh`** - Main startup script that launches Chromium with proper configuration
- **`chromium-kiosk.desktop`** - Autostart desktop entry file
- **`README.md`** - This documentation file
## Overview
This setup configures Chromium to:
- Start automatically on boot
- Open in fullscreen mode at `http://127.0.0.1:8080`
- Avoid keyring password prompts
- Prevent restore session notifications
- Properly fill the entire screen (fixes Wayland/X11 fullscreen issues)
- Support both fullscreen and kiosk modes (switchable via script)
## Installation
### Prerequisites
1. **SSH access** to the Raspberry Pi device
2. **Auto-login enabled** (required for autostart to work)
3. **Chromium installed**: `sudo apt-get install chromium`
4. **wmctrl installed**: `sudo apt-get install wmctrl` (for fullscreen forcing)
### Setup Steps
1. **Copy the startup script to the device:**
```bash
scp start-chromium.sh pi@<device-ip>:/home/pi/start-chromium.sh
ssh pi@<device-ip> "chmod +x /home/pi/start-chromium.sh"
```
2. **Create autostart directory and copy desktop file:**
```bash
ssh pi@<device-ip> "mkdir -p ~/.config/autostart"
scp chromium-kiosk.desktop pi@<device-ip>:/home/pi/.config/autostart/chromium-kiosk.desktop
```
3. **Install wmctrl (if not already installed):**
```bash
ssh pi@<device-ip> "sudo apt-get update && sudo apt-get install -y wmctrl"
```
4. **Reboot to test:**
```bash
ssh pi@<device-ip> "sudo reboot"
```
## Configuration
### Switching Between Fullscreen and Kiosk Mode
Edit `/home/pi/start-chromium.sh` on the device:
- **Fullscreen mode** (current): Uncomment the fullscreen line, comment out the kiosk line
- **Kiosk mode**: Comment out the fullscreen line, uncomment the kiosk line
### Changing the URL
Edit the `--app=http://127.0.0.1:8080` parameter in `start-chromium.sh` to point to your desired URL.
### Adjusting Delays
If Chromium doesn't start properly on boot, you may need to increase delays:
- Line 25: `sleep 5` - Delay before starting Chromium
- Line 32: `sleep 3` - Delay before forcing fullscreen
## Troubleshooting
### Chromium doesn't start on boot
- Verify auto-login is enabled: `sudo raspi-config` → Boot Options → Desktop Autologin
- Check if the script is executable: `chmod +x ~/start-chromium.sh`
- Check autostart file exists: `ls -la ~/.config/autostart/chromium-kiosk.desktop`
### Fullscreen doesn't work properly
- Ensure `wmctrl` is installed: `sudo apt-get install wmctrl`
- Check if X11 is being used (not Wayland): The script forces X11 with `--ozone-platform=x11`
- Manually test: `DISPLAY=:0 ~/start-chromium.sh`
### Keyring password prompt appears
- The script includes `--password-store=basic --use-mock-keychain` flags
- If it still appears, you may need to set an empty password for the keyring once
### Restore session notification appears
- The script includes `--disable-session-crashed-bubble --disable-restore-session-state` flags
- If it still appears, clear Chromium's session data: `rm -rf ~/.config/chromium/Session*`
## Manual Testing
Test the script without rebooting:
```bash
ssh pi@<device-ip> "pkill chromium && sleep 2 && DISPLAY=:0 ~/start-chromium.sh"
```
## Exiting Fullscreen/Kiosk Mode
- **Fullscreen mode**: Press `F11` to toggle fullscreen, or `Alt+F4` to close
- **Kiosk mode**: Use `Ctrl+Alt+T` to open terminal, then `pkill chromium`
- **From SSH**: `ssh pi@<device-ip> "pkill chromium"`
## Disabling Autostart
To temporarily disable autostart:
```bash
ssh pi@<device-ip> "mv ~/.config/autostart/chromium-kiosk.desktop ~/.config/autostart/chromium-kiosk.desktop.disabled"
```
To re-enable:
```bash
ssh pi@<device-ip> "mv ~/.config/autostart/chromium-kiosk.desktop.disabled ~/.config/autostart/chromium-kiosk.desktop"
```
## Chromium Flags Explained
- `--start-fullscreen` - Start in fullscreen mode
- `--kiosk` - Kiosk mode (no UI, harder to exit)
- `--noerrdialogs` - Suppress error dialogs
- `--disable-infobars` - Remove info bars
- `--disable-session-crashed-bubble` - Disable crash notifications
- `--disable-restore-session-state` - Don't restore previous session
- `--no-first-run` - Skip first-run dialogs
- `--password-store=basic` - Use unencrypted password store (no keyring)
- `--use-mock-keychain` - Avoid keychain prompts
- `--ozone-platform=x11` - Force X11 instead of Wayland (better fullscreen)
- `--app=<url>` - Run as app (no address bar, cleaner interface)
## Device Information
- **Device**: reTerminal DM4 (Raspberry Pi)
- **OS**: Raspberry Pi OS (Debian-based)
- **Tested on**: Linux raspberrypi 6.12.62+rpt-rpi-v8
## Notes
- The script waits for the desktop environment to be ready before starting Chromium
- It uses `wmctrl` to programmatically force fullscreen after Chromium starts
- X11 is forced instead of Wayland for better fullscreen compatibility
- The script runs in the background and maintains the Chromium process
## License
This configuration is provided as-is for use with the reTerminal DM4 project.

View File

@@ -11,24 +11,35 @@ emmc-provisioning/
├── README.md ← You are here
├── docs/ Documentation
│ ├── EMMC-PROVISIONING-GUIDE.md Full setup and usage
│ ├── NETWORK-BOOT-LXC.md Network boot (PXE/dnsmasq) and LXC
│ ├── PROXMOX-LXC-DEPLOYMENT.md Proxmox LXC + host setup
│ └── PORTAL_STYLING_GUIDE.md Dashboard UI styling reference
├── host/ Scripts that run on the provisioning host (Proxmox host)
│ ├── flash-emmc-on-connect.sh rpiboot + wait for Backup/Deploy choice, then dd
│ ├── cm4-flash-trigger.sh Called by udev; starts the flash job
── 90-cm4-boot-mode.rules udev rule (USB vendor 2b8e)
── build-cloudinit-image.sh Build golden image with cloud-init
│ └── run-shrink-on-host.sh PiShrink (optional)
├── scripts/ Deployment and one-off scripts
│ ├── deploy-to-proxmox.sh One-command deploy to Proxmox host + LXC (by hostname)
── install-usbboot-on-host.sh Build and install rpiboot on the host
│ ├── deploy-to-proxmox.sh Deploy to Proxmox host + LXC
── sync-portal-files-to-lxc.sh Sync cloud-init/first-boot assets to file server (LXC)
│ ├── setup-network-boot-on-lxc.sh Configure PXE/dnsmasq for network boot
│ ├── install-usbboot-on-host.sh Build and install rpiboot on the host
│ └── ... (other deploy/monitor scripts)
├── dashboard/ Flask web UI (runs in LXC or standalone)
│ ├── app.py
│ ├── templates/
│ ├── cm4-dashboard.service
│ └── README.md
├── cloud-init/ Example NoCloud files for the golden image
│ ├── user-data
│ ├── meta-data
── network-config
├── cloud-init/ First-boot and file-server assets
│ ├── first-boot.sh Main first-boot script (run by cloud-init)
│ ├── first-boot.md Documentation for first-boot.sh
── start-chromium.sh Chromium kiosk launcher (→ file server)
│ ├── user-data-remote-gnss.example Example cloud-init user-data (curl first-boot.sh)
│ ├── config-files/ LightDM, Maliit, one-shots (.desktop + scripts)
│ │ ├── chromium-kiosk.desktop
│ │ ├── set-rotation-once.desktop
│ │ └── ...
│ ├── files-from-guard/ Plymouth, splash assets; README of required files
│ └── fix-reterminal-display.sh One-time fix script (splash, rotation, wallpaper)
├── lxc/ LXC config snippets (dnsmasq, nftables)
└── network-client/ For network-booted devices
├── provisioning-client.sh Register + poll, then Deploy or Backup
└── README.md

View File

@@ -4,9 +4,10 @@ first-boot.sh downloads these from `FILE_SERVER` (e.g. `http://10.130.60.141:500
| File on server | Destination on device |
|----------------|------------------------|
| chromium-kiosk.desktop | /home/pi/.config/autostart/chromium-kiosk.desktop (with start-chromium.sh) |
| 99-wallpaper.conf | /etc/lightdm/lightdm.conf.d/99-wallpaper.conf |
| 99-default-session.conf | /etc/lightdm/lightdm.conf.d/99-default-session.conf (rpd-labwc) |
| maliit-keyboard.desktop | /home/pi/.config/autostart/maliit-keyboard.desktop |
| set-rotation-once.desktop | /home/pi/.config/autostart/set-rotation-once.desktop (with set-rotation-once.sh) |
Wallpaper is set once during first-boot by creating `~/.config/labwc/autostart` with swaybg; no set-wallpaper-once one-shot.
Wallpaper is set once during first-boot via pcmanfm config; no set-wallpaper-once one-shot.

View File

@@ -16,7 +16,7 @@ first-boot.sh downloads from **`.../files/first-boot/`** (e.g. `http://10.130.60
| **maliit-keyboard.desktop** | Maliit on-screen keyboard autostart (from `config-files/`). |
| **set-rotation-once.sh** + **.desktop** | One-shot: wlr-randr rotation (Left) at first login. |
Desktop wallpaper is set once during first-boot (labwc autostart created by first-boot.sh); no set-wallpaper-once needed.
Desktop wallpaper is set once during first-boot via pcmanfm config (first-boot.sh); no set-wallpaper-once one-shot needed.
---
@@ -26,4 +26,5 @@ Desktop wallpaper is set once during first-boot (labwc autostart created by firs
- **plymouth-custom/custom.plymouth** — Plymouth theme definition; host as `custom.plymouth`.
- **plymouth-custom/custom.script** — Plymouth script that draws splash.png; host as `custom.script`.
- **lightdm/RPiSystem_dark.png** — Unused; only `splash.png` is used now.
- **set-rotation-once.sh** lives in `cloud-init/`; copy it (and its .desktop) into `portal-files/first-boot/` on the file server.
- **start-chromium.sh** and **chromium-kiosk.desktop** live in `cloud-init/` and `cloud-init/config-files/`; `scripts/sync-portal-files-to-lxc.sh` copies them to the portal first-boot folder.
- **set-rotation-once.sh** (and its .desktop) are in `cloud-init/` and synced to `portal-files/first-boot/` by the same script.

View File

@@ -8,7 +8,7 @@ export DEBIAN_FRONTEND=noninteractive
# --- Constants ---
# All first-boot assets live in portal-files/first-boot/ on the file server.
FILE_SERVER="http://10.130.60.141:5000/files/first-boot"
HOSTNAME="gnss.guard"
HOSTNAME="guard"
PI_USER="pi"
PI_HOME="/home/$PI_USER"
AUTOSTART="$PI_HOME/.config/autostart"
@@ -190,8 +190,12 @@ if [[ -f "$CMDLINE_PATH" ]] && ! grep -q 'swiotlb=' "$CMDLINE_PATH"; then
log "Added swiotlb=65536 to kernel cmdline (vc4-drm / DSI)"
fi
# --- 6c. CM4: enable rpi-eeprom-update (flashrom + config.txt [cm4] block) so boot order can be set ---
# On CM4, rpi-eeprom-update is disabled by default. Enable it so we can set BOOT_ORDER=0x21 (network first).
# --- 6c. CM4: enable rpi-eeprom-update so boot order can be set ---
# On CM4, rpi-eeprom-update is disabled by default. Enable it by setting flags in /etc/default/rpi-eeprom-update.
# We use the bootloader method (pieeprom.upd file placed in /boot/firmware), NOT flashrom.
# NOTE: Do NOT add dtoverlay=audremap or dtoverlay=spi-gpio40-45 to config.txt.
# Those are only needed for the flashrom (direct SPI) method, and audremap CONFLICTS with
# the reTerminal DM display backlight (both use GPIO13 PWM).
# See: https://github.com/raspberrypi/usbboot , /etc/default/rpi-eeprom-update
log "--- CM4 EEPROM update enable (for boot order) ---"
EEPROM_DEFAULT="/etc/default/rpi-eeprom-update"
@@ -202,18 +206,6 @@ fi
grep -q '^RPI_EEPROM_USE_FLASHROM=' "$EEPROM_DEFAULT" && sed -i 's/^RPI_EEPROM_USE_FLASHROM=.*/RPI_EEPROM_USE_FLASHROM=1/' "$EEPROM_DEFAULT" || echo 'RPI_EEPROM_USE_FLASHROM=1' >> "$EEPROM_DEFAULT"
grep -q '^CM4_ENABLE_RPI_EEPROM_UPDATE=' "$EEPROM_DEFAULT" && sed -i 's/^CM4_ENABLE_RPI_EEPROM_UPDATE=.*/CM4_ENABLE_RPI_EEPROM_UPDATE=1/' "$EEPROM_DEFAULT" || echo 'CM4_ENABLE_RPI_EEPROM_UPDATE=1' >> "$EEPROM_DEFAULT"
log "Set RPI_EEPROM_USE_FLASHROM=1 and CM4_ENABLE_RPI_EEPROM_UPDATE=1 in $EEPROM_DEFAULT"
# config.txt: [cm4] section with SPI for EEPROM (only applied when booting a CM4)
if [[ -f "$CFG_PATH" ]]; then
if ! grep -q '^\[cm4\]' "$CFG_PATH"; then
printf '%s\n' '' '[cm4]' 'dtparam=spi=on' 'dtoverlay=audremap' 'dtoverlay=spi-gpio40-45' >> "$CFG_PATH"
log "Added [cm4] block (spi, audremap, spi-gpio40-45) to config.txt for EEPROM"
else
for ENTRY in 'dtparam=spi=on' 'dtoverlay=audremap' 'dtoverlay=spi-gpio40-45'; do
grep -q "^$ENTRY" "$CFG_PATH" || echo "$ENTRY" >> "$CFG_PATH"
done
log "Ensured [cm4] EEPROM entries in config.txt"
fi
fi
# --- 6d. Boot order: network first, then eMMC/SD (for future network boot / re-provisioning) ---
# BOOT_ORDER: 0x2 = network, 0x1 = SD/eMMC. 0x21 = try network first, then local storage.

View File

@@ -1,7 +1,7 @@
#cloud-config
# Example: create user (pi) with password, enable SSH, install KDE Plasma with touch options,
# set KDE as default GUI, and deploy Chromium kiosk autostart.
# Uses start-chromium.sh and chromium-kiosk.desktop from this project (chromium-setup/).
# Uses start-chromium.sh and chromium-kiosk.desktop from this project (emmc-provisioning/cloud-init/).
#
# 1. Generate a password hash on a Linux host:
# mkpasswd -m sha-512 'YourPassword'

View File

@@ -48,8 +48,8 @@ sudo cp rpiboot /opt/usbboot/
#### 3. Install the provisioning script and trigger
```bash
# From this repo (chromium-setup/emmc-provisioning/host/)
cd chromium-setup/emmc-provisioning/host
# From this repo (emmc-provisioning/host/)
cd emmc-provisioning/host
sudo mkdir -p /opt/cm4-provisioning
sudo cp flash-emmc-on-connect.sh /opt/cm4-provisioning/
@@ -199,7 +199,7 @@ Raw full-disk backups and golden images are the full size of the eMMC (e.g. 32
```bash
# From this repo (on the host or via ssh)
bash chromium-setup/emmc-provisioning/scripts/install-pishrink-on-host.sh
bash emmc-provisioning/scripts/install-pishrink-on-host.sh
```
This installs `parted`, `e2fsprogs`, `gzip`, `pigz`, `xz-utils` and downloads `pishrink.sh` to `/usr/local/bin/pishrink.sh`.

View File

@@ -27,7 +27,7 @@ From your machine, run the setup script **on the LXC** (replace with your LXC IP
```bash
# From the repo (script runs inside the LXC)
./chromium-setup/emmc-provisioning/scripts/setup-network-boot-on-lxc.sh root@10.130.60.141
./emmc-provisioning/scripts/setup-network-boot-on-lxc.sh root@10.130.60.141
```
Or SSH into the LXC and run the script there:
@@ -79,7 +79,7 @@ The setup script **automatically downloads** the official Raspberry Pi firmware
To refresh or populate TFTP without re-running the full setup:
```bash
./chromium-setup/emmc-provisioning/scripts/populate-tftpboot-from-git.sh root@<LXC-IP>
./emmc-provisioning/scripts/populate-tftpboot-from-git.sh root@<LXC-IP>
```
(Remove `/srv/tftpboot/start4cd.elf` on the LXC first if you want a full re-fetch.)

View File

@@ -7,7 +7,7 @@ The auto-flash **runs on the Proxmox host** (where the USB device appears). The
From your repo, a single run deploys **all** host and LXC files (scripts, systemd units, udev, dashboard):
```bash
./chromium-setup/emmc-provisioning/scripts/deploy-to-proxmox.sh root@YOUR_PROXMOX_HOST
./emmc-provisioning/scripts/deploy-to-proxmox.sh root@YOUR_PROXMOX_HOST
```
Optional env: `CM4_BACKUPS_HOST_PATH=/path`, `DEPLOY_ROOTFS_STORAGE=local-lvm`, `DEPLOY_LXC_ROOT_PASSWORD=secret` (set root password in LXC and enable SSH), `DEPLOY_LXC_SSH_KEY=/path/to/pub` (default: `~/.ssh/id_ed25519.pub` or `id_rsa.pub` — copied to LXC root so you can `ssh root@<LXC-IP>`).
@@ -59,7 +59,7 @@ On your machine (repo already synced to the host):
```bash
# From your repo
scp chromium-setup/emmc-provisioning/scripts/install-usbboot-on-host.sh root@10.130.60.224:/tmp/
scp emmc-provisioning/scripts/install-usbboot-on-host.sh root@10.130.60.224:/tmp/
ssh root@10.130.60.224 "bash /tmp/install-usbboot-on-host.sh"
```
@@ -82,10 +82,10 @@ Otherwise, to enable root SSH and add a key:
```bash
# Add your default SSH key (~/.ssh/id_ed25519.pub or id_rsa.pub) and enable root SSH
./chromium-setup/emmc-provisioning/scripts/setup-lxc-ssh.sh root@10.130.60.224
./emmc-provisioning/scripts/setup-lxc-ssh.sh root@10.130.60.224
# Or specify key file and set root password
ROOT_PASSWORD='YourPassword' ./chromium-setup/emmc-provisioning/scripts/setup-lxc-ssh.sh root@10.130.60.224 ~/.ssh/id_ed25519.pub
ROOT_PASSWORD='YourPassword' ./emmc-provisioning/scripts/setup-lxc-ssh.sh root@10.130.60.224 ~/.ssh/id_ed25519.pub
```
Then connect with `ssh root@<LXC-IP>` (script prints the IP). To get the LXC IP:
@@ -101,7 +101,7 @@ To keep backup images on a specific host path (e.g. a large disk or NFS mount) i
**Deploy with a host backup path:**
```bash
CM4_BACKUPS_HOST_PATH=/mnt/storage/cm4-backups ./chromium-setup/emmc-provisioning/scripts/deploy-to-proxmox.sh root@10.130.60.224
CM4_BACKUPS_HOST_PATH=/mnt/storage/cm4-backups ./emmc-provisioning/scripts/deploy-to-proxmox.sh root@10.130.60.224
```
Create `/mnt/storage/cm4-backups` (or your path) on the host first if it doesnt exist; the deploy script will create it if possible. To add or change the backup mount, set `CM4_BACKUPS_HOST_PATH` and run the deploy script again (it reuses the container by hostname and updates the bind mount).
@@ -130,7 +130,7 @@ The dashboard shows **connection steps** and **live deployment status** (idle /
```bash
# Copy dashboard into the container (from host, if you have the repo there)
# Or from your workstation:
# rsync -a chromium-setup/emmc-provisioning/dashboard/ root@10.130.60.224:/tmp/dashboard/
# rsync -a emmc-provisioning/dashboard/ root@10.130.60.224:/tmp/dashboard/
# Or re-run deploy-to-proxmox.sh to push the latest dashboard files.
# Inside the LXC (pct exec <CTID> -- bash):
@@ -189,7 +189,7 @@ From the **Proxmox host** you can monitor:
```bash
# From your machine (stream script to host):
ssh root@10.130.60.224 'bash -s' < chromium-setup/emmc-provisioning/scripts/monitor-from-host.sh
ssh root@10.130.60.224 'bash -s' < emmc-provisioning/scripts/monitor-from-host.sh
```
Or copy `scripts/monitor-from-host.sh` to the host and run `./monitor-from-host.sh` for a full status dump (USB, status.json, flash unit, last log lines, block devices, config).
@@ -200,7 +200,7 @@ Or copy `scripts/monitor-from-host.sh` to the host and run `./monitor-from-host.
1. **Host has old flash script** The script must *not* exit when the golden image is missing (so you can use Backup first). Update the host:
```bash
scp chromium-setup/emmc-provisioning/host/flash-emmc-on-connect.sh root@10.130.60.224:/opt/cm4-provisioning/
scp emmc-provisioning/host/flash-emmc-on-connect.sh root@10.130.60.224:/opt/cm4-provisioning/
ssh root@10.130.60.224 "chmod +x /opt/cm4-provisioning/flash-emmc-on-connect.sh"
```
@@ -212,7 +212,7 @@ Or copy `scripts/monitor-from-host.sh` to the host and run `./monitor-from-host.
4. **Clear stuck error in portal** If the portal shows an old error (e.g. "Golden image not found" or "rpiboot failed"), click **Clear message** in the dashboard, or: `ssh root@10.130.60.224 "echo '{\"phase\":\"idle\",\"message\":\"Waiting for reTerminal in boot mode or network.\",\"progress\":null}' > /var/lib/cm4-provisioning/status.json"`. Then unplug/replug the device.
5. **"PiShrink not installed" when clicking Shrink/Compress** Shrink and Compress run **on the host**, not in the LXC. Install PiShrink on the host: `ssh root@HOST 'bash -s' < chromium-setup/emmc-provisioning/scripts/install-pishrink-on-host.sh`. Ensure deploy has been run so the host has `run-shrink-on-host.sh` and `cm4-shrink.path` enabled (`systemctl status cm4-shrink.path`).
5. **"PiShrink not installed" when clicking Shrink/Compress** Shrink and Compress run **on the host**, not in the LXC. Install PiShrink on the host: `ssh root@HOST 'bash -s' < emmc-provisioning/scripts/install-pishrink-on-host.sh`. Ensure deploy has been run so the host has `run-shrink-on-host.sh` and `cm4-shrink.path` enabled (`systemctl status cm4-shrink.path`).
6. **"Download failed" when building cloud-init image** The download runs on the **host** (not the LXC). Check: (1) Host can reach the internet: `ssh root@HOST 'curl -sI https://downloads.raspberrypi.com/'`. (2) Build status now shows curls error (e.g. "Could not resolve host", "Connection timed out"); check the dashboard error text. (3) If you use a proxy or custom CA, set in `/opt/cm4-provisioning/env`: `CURL_INSECURE=1` to skip SSL verify (only if you understand the risk), then rerun the build.
@@ -227,7 +227,7 @@ Or copy `scripts/monitor-from-host.sh` to the host and run `./monitor-from-host.
From your repo (e.g. after changing scripts):
```bash
./chromium-setup/emmc-provisioning/scripts/deploy-to-proxmox.sh root@10.130.60.224
./emmc-provisioning/scripts/deploy-to-proxmox.sh root@10.130.60.224
```
That script syncs the repo to the host and reinstalls scripts on both the host and LXC 201. It does **not** overwrite `/opt/cm4-provisioning/env` or `/etc/cm4-provisioning/enabled` if youve changed them; adjust the script if you want that. It also does **not** build usbboot; run `install-usbboot-on-host.sh` on the host when needed.

View File

@@ -10,7 +10,7 @@ Config files for the **provisioning LXC** when using **eth1** as a provisioning
Setup is done by running (from your machine):
```bash
./chromium-setup/emmc-provisioning/scripts/setup-network-boot-on-lxc.sh root@<LXC-IP>
./emmc-provisioning/scripts/setup-network-boot-on-lxc.sh root@<LXC-IP>
```
See [../docs/NETWORK-BOOT-LXC.md](../docs/NETWORK-BOOT-LXC.md) for full documentation.

View File

@@ -4,7 +4,7 @@
# This script removes broken symlinks and extracts bootcode4.bin from the installed rpiboot binary.
#
# On host: bash fix-gadget-bootcode-on-host.sh
# From your machine: ssh root@HOST 'bash -s' < chromium-setup/emmc-provisioning/scripts/fix-gadget-bootcode-on-host.sh
# From your machine: ssh root@HOST 'bash -s' < emmc-provisioning/scripts/fix-gadget-bootcode-on-host.sh
set -e
GADGET="${1:-/opt/usbboot/mass-storage-gadget64}"

View File

@@ -25,11 +25,14 @@ ssh "$LXC" "mkdir -p $REMOTE_FIRST_BOOT"
# first-boot.sh at portal root (cloud-init downloads it by URL, not from first-boot/ subfolder)
rsync -avz "$CLOUDINIT_DIR/first-boot.sh" "$LXC:$REMOTE_PORTAL/"
# config-files/* → portal-files/first-boot/
# config-files/* (includes chromium-kiosk.desktop) → portal-files/first-boot/
rsync -avz --exclude='README.md' \
"$CLOUDINIT_DIR/config-files/" \
"$LXC:$REMOTE_FIRST_BOOT/"
# start-chromium.sh → portal-files/first-boot/
rsync -avz "$CLOUDINIT_DIR/start-chromium.sh" "$LXC:$REMOTE_FIRST_BOOT/"
# plymouth-custom/* (custom.plymouth, custom.script, splash.png if present) → portal-files/first-boot/
rsync -avz \
"$CLOUDINIT_DIR/files-from-guard/plymouth-custom/" \

Some files were not shown because too many files have changed in this diff Show More