ops: appliance boot — wait for cameras/LiveKit, power button powers off
This commit is contained in:
@@ -1,20 +1,28 @@
|
||||
[Unit]
|
||||
Description=Publish C920 cameras (speechbrain audio) to LiveKit
|
||||
Documentation=file:///home/fdenkena/livekit-cameras/README.md
|
||||
After=network-online.target sound.target livekit-server.service
|
||||
Wants=network-online.target
|
||||
Requires=livekit-server.service
|
||||
# Wants, not Requires: local livekit-server is a test stand-in.
|
||||
# Point LIVEKIT_URL at a remote server later and you can disable this unit.
|
||||
Wants=livekit-server.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/home/fdenkena/livekit-cameras
|
||||
EnvironmentFile=-/home/fdenkena/livekit-cameras/.env
|
||||
Environment=PYTHONUNBUFFERED=1
|
||||
Environment=ENHANCE_MODE=force
|
||||
ExecStartPre=/home/fdenkena/livekit-cameras/deploy/wait-for-cameras.sh
|
||||
ExecStartPre=/home/fdenkena/livekit-cameras/deploy/wait-for-livekit.sh
|
||||
ExecStart=/home/fdenkena/livekit-cameras/.venv/bin/python /home/fdenkena/livekit-cameras/run.py
|
||||
ExecStop=/bin/kill -TERM $MAINPID
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
TimeoutStartSec=90
|
||||
TimeoutStopSec=30
|
||||
KillMode=control-group
|
||||
Environment=PYTHONUNBUFFERED=1
|
||||
Environment=LIVEKIT_URL=ws://127.0.0.1:7880
|
||||
Environment=ENHANCE_MODE=force
|
||||
KillSignal=SIGTERM
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
Reference in New Issue
Block a user