23 lines
667 B
SYSTEMD
23 lines
667 B
SYSTEMD
|
|
[Unit]
|
||
|
|
Description=Archipelago Kiosk (X11 + Chromium)
|
||
|
|
After=archipelago.service graphical.target
|
||
|
|
Wants=archipelago.service
|
||
|
|
ConditionPathExists=/usr/local/bin/archipelago-kiosk-x11
|
||
|
|
Conflicts=getty@tty1.service
|
||
|
|
|
||
|
|
[Service]
|
||
|
|
Type=simple
|
||
|
|
User=archipelago
|
||
|
|
Environment="HOME=/home/archipelago"
|
||
|
|
Environment="DISPLAY=:0"
|
||
|
|
# Wait for backend before launching UI
|
||
|
|
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'
|
||
|
|
ExecStart=/usr/bin/startx /usr/local/bin/archipelago-kiosk-x11 -- -nocursor vt1
|
||
|
|
Restart=always
|
||
|
|
RestartSec=5
|
||
|
|
StandardInput=tty
|
||
|
|
TTYPath=/dev/tty1
|
||
|
|
|
||
|
|
[Install]
|
||
|
|
WantedBy=multi-user.target
|