added start script
This commit is contained in:
parent
d431398bd8
commit
4e3c70e280
1
app.py
Normal file → Executable file
1
app.py
Normal file → Executable file
@ -1,3 +1,4 @@
|
||||
#!/tilde/lyadmin/venv/bin/python3
|
||||
import glob
|
||||
import json
|
||||
|
||||
|
27
perl-script/conf/lyctl.sh
Normal file
27
perl-script/conf/lyctl.sh
Normal file
@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
|
||||
ACMD="$1"
|
||||
ARGV="$@"
|
||||
|
||||
. /tilde/lyadmin/venv/bin/activate
|
||||
|
||||
INSTDIR='/tilde/lyadmin'
|
||||
LINGYIND="$INSTDIR/app.py"
|
||||
ERROR=0
|
||||
|
||||
USAGESTR='Usage:) lyctl.sh start'
|
||||
|
||||
case $ACMD in
|
||||
start)
|
||||
cd $INSTDIR
|
||||
$LINGYIND
|
||||
$ERROR=$?
|
||||
;;
|
||||
*)
|
||||
echo "no valid aguments..."
|
||||
echo $USAGESTR
|
||||
ERROR=2
|
||||
esac
|
||||
|
||||
exit $ERROR
|
||||
|
Loading…
Reference in New Issue
Block a user