Compare commits

...

2 Commits

Author SHA1 Message Date
gashapwn
a341e8ccc4 provision.pl - modified rcctl start for lingyind 2020-12-05 22:35:34 +00:00
gashapwn
604f75afc8 lingyin.rc - now uses lyctl.sh to start 2020-12-05 22:26:03 +00:00
2 changed files with 13 additions and 3 deletions

View File

@ -2,14 +2,24 @@
#
# lingyind
daemon="cd /tilde/lyadmin/ && . /tilde/lyadmin/venv/bin/activate && python3 /tilde/lyadmin/app.py &"
#daemon="cd /tilde/lyadmin/ && . /tilde/lyadmin/venv/bin/activate && python3 /tilde/lyadmin/app.py &"
daemon="/tilde/lyadmin/perl-script/conf/lyctl.sh"
daemon_user="_lingyind"
. /etc/rc.d/rc.subr
pexp="python3 /tilde/lyadmin/app.py"
#pexp="python3 /tilde/lyadmin/app.py"
pexp="/tilde/lyadmin/venv/bin/python3 /tilde/lyadmin/app.py"
rc_reload=NO
rc_start() {
${daemon} start
}
rc_check(){
pgrep -f "^${pexp}" > /dev/null
}
rc_stop() {
pkill -f "^${pexp}"
}

View File

@ -74,7 +74,7 @@ system("su $SVC_ACCT -c '. ./venv/bin/activate && pip3 install -r requirements.t
system("cp ./perl-script/conf/lingyin.rc /etc/rc.d/lingyind");
system("chmod 755 /etc/rc.d/lingyind");
system("rcctl enable lingyind");
exec("rcctl start lingyind");
system("rcctl start lingyind");
system("pkg_add p5-JSON");