mirror of
https://github.com/playit-cloud/playit-agent.git
synced 2026-07-04 03:58:49 +00:00
* Add optional service manager selection for installed playit - Add `--systemd` and `--openrc` on Linux - Route start/stop/setup flows through the selected manager - Add OpenRC support and manager-specific error messages * Add init-manager aware Linux packaging - Package systemd and OpenRC service files from one nfpm config - Detect the active init system in postinstall and install the matching service - Route `linux/playit` through the chosen manager when present
22 lines
526 B
Plaintext
22 lines
526 B
Plaintext
#!/sbin/openrc-run
|
|
|
|
name="Playit Agent"
|
|
description="Playit Agent"
|
|
|
|
command="/opt/playit/playitd"
|
|
command_args="--secret-path /etc/playit/playit.toml --socket-path /run/playit/playitd.sock -l /var/log/playit/playit.log"
|
|
command_user="playit:playit"
|
|
command_background=true
|
|
pidfile="/run/playit/playitd.pid"
|
|
|
|
depend() {
|
|
need net
|
|
after firewall
|
|
}
|
|
|
|
start_pre() {
|
|
checkpath -d -m 0750 -o playit:playit /run/playit
|
|
checkpath -d -m 0750 -o playit:playit /etc/playit
|
|
checkpath -d -m 0750 -o playit:playit /var/log/playit
|
|
}
|