fix(fips,kiosk): auto-activate FIPS at onboarding end + 5-min kiosk wait
1. FIPS auto-activate at server startup only fires if fips_key already exists on disk, which on a fresh install is never true until AFTER onboarding. By the time the user completes seed-generate/restore, archipelago has been running for minutes and the startup task has long since exited. User still had to hit Activate. Fix: call spawn_post_onboarding_fips_activate() from the tail of handle_seed_generate and handle_seed_restore — the moment the fips_key materialises, a detached task runs `fips::config::install` + `archipelago-fips.service activate`. Logged only, never blocks the onboarding RPC. 2. Kiosk health-poll window was 30 × 2s (configs/ copy was 60 × 2s but unused — the heredoc in build-auto-installer-iso.sh is what actually lands on disk). On .198's slower hardware archipelago /health wasn't ready within 60s, so Chromium launched against a not-yet-running backend → blank window until manual reboot. Bumped to 150 × 2s (5 min) + TimeoutStartSec=360. .253 was already well within the window; this protects the slower box too. Standalone configs/archipelago-kiosk.service updated in lockstep so the two copies don't drift. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.7
parent
78e7c59e78
commit
6b78bd692d
@@ -2648,15 +2648,22 @@ chmod +x /mnt/target/usr/local/bin/archipelago-kiosk-launcher
|
||||
cat > /mnt/target/etc/systemd/system/archipelago-kiosk.service <<'KIOSKSVC'
|
||||
[Unit]
|
||||
Description=Archipelago Kiosk (X11 + Chromium)
|
||||
After=archipelago.service
|
||||
Wants=archipelago.service
|
||||
After=archipelago.service systemd-user-sessions.service network-online.target
|
||||
Wants=archipelago.service network-online.target
|
||||
ConditionPathExists=/usr/local/bin/archipelago-kiosk-launcher
|
||||
Conflicts=getty@tty1.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStartPre=/bin/bash -c 'for i in $(seq 1 30); do curl -sf http://localhost/health >/dev/null 2>&1 && exit 0; sleep 2; done; exit 0'
|
||||
# First-boot health-poll window is 300s (150 × 2s). Slow hardware
|
||||
# (e.g. the atom-class box at .198) was blowing past the old 60s /
|
||||
# 120s window, so Chromium launched against a not-yet-ready backend
|
||||
# and showed a blank window that only recovered on reboot. At 300s
|
||||
# even the unbundled-FileBrowser-pull + archipelago state sync + frontend
|
||||
# settle fits with headroom. TimeoutStartSec is bumped in lockstep.
|
||||
ExecStartPre=/bin/bash -c 'for i in $(seq 1 150); do curl -sf http://localhost/health >/dev/null 2>&1 && exit 0; sleep 2; done; exit 0'
|
||||
ExecStart=/usr/local/bin/archipelago-kiosk-launcher
|
||||
TimeoutStartSec=90
|
||||
TimeoutStartSec=360
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
|
||||
Reference in New Issue
Block a user