MOON
Server: Apache
System: Linux vps.erhabenn.com.br 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64
User: sonne (1011)
PHP: 8.2.31
Disabled: NONE
Upload Files
File: //etc/rc.d/rc6.d/K50sync-daemon
#!/bin/sh
### BEGIN INIT INFO
# Provides:          sync-daemon
# Required-Start:    $network
# Required-Stop:     $network
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Description:       Sync daemon
### END INIT INFO

BIN_PATH_VAR="$BIN_PATH"

case "$1" in
    start)
        echo "Starting sync daemon..."
        $BIN_PATH_VAR &
        ;;
    stop)
        echo "Stopping sync daemon..."
        pkill -f "$(basename $BIN)"
        ;;
    restart)
        $0 stop
        sleep 2
        $0 start
        ;;
esac