txtdot/txtdot.init

28 lines
569 B
Plaintext
Raw Normal View History

2023-08-31 13:21:38 +03:00
#!/sbin/openrc-run
#export HOST=127.0.0.1
#export PORT=8080
#export REVERSE_PROXY=true
name=$RC_SVCNAME
command="/usr/bin/node"
command_args="./src/app.js"
command_user="txtdot"
directory="/home/txtdot/src/dist"
output_log="/var/log/$RC_SVCNAME/txtdot.log"
error_log="/var/log/$RC_SVCNAME/error.log"
pidfile="/run/$RC_SVCNAME/$RC_SVCNAME.pid"
stopsig="KILL"
command_background="yes"
depend() {
need net
}
start_pre() {
checkpath --directory --owner $command_user:$command_user --mode 0775 \
/run/$RC_SVCNAME /var/log/$RC_SVCNAME
}