mirror of
https://github.com/YunoHost-Apps/ffsync_ynh.git
synced 2024-09-03 18:26:38 +02:00
Merge pull request #8 from matlink/patch-1
[upd] add status for service
This commit is contained in:
commit
bf954be3ef
1 changed files with 13 additions and 0 deletions
13
conf/ffsync
13
conf/ffsync
|
@ -43,6 +43,16 @@ stop() {
|
|||
rm -f ${pidfile}
|
||||
}
|
||||
|
||||
status(){
|
||||
if [[ -f ${pidfile} ]]; then
|
||||
echo "Status: running."
|
||||
exit 0;
|
||||
else
|
||||
echo "Status: not running."
|
||||
exit 1;
|
||||
fi
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
start
|
||||
|
@ -50,6 +60,9 @@ case "$1" in
|
|||
stop)
|
||||
stop
|
||||
;;
|
||||
status)
|
||||
status
|
||||
;;
|
||||
restart)
|
||||
stop
|
||||
start
|
||||
|
|
Loading…
Reference in a new issue