mirror of
https://github.com/commaai/agnos-builder.git
synced 2026-07-18 13:22:04 +08:00
systemd: configure comma service to allow start/stop (#427)
* correct service config * restart not compatible with oneshot, but never worked anyway
This commit is contained in:
@@ -2,10 +2,12 @@
|
||||
After=local-fs.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Type=oneshot
|
||||
RemainAfterExit=true
|
||||
User=comma
|
||||
Restart=always
|
||||
ExecStart=/bin/bash -c "/usr/bin/tmux new-session -s comma -d /usr/comma/comma.sh && sleep infinity"
|
||||
ExecStart=/bin/bash -c "/usr/bin/tmux new-session -s comma -d /usr/comma/comma.sh"
|
||||
# TODO: send SIGTERM first, then kill after a timeout
|
||||
ExecStop=/bin/bash -c "/usr/bin/tmux kill-session -t comma"
|
||||
TimeoutStopSec=1
|
||||
LimitRTPRIO=100
|
||||
LimitNICE=-10
|
||||
|
||||
Reference in New Issue
Block a user