diff --git a/debian/sylkserver.init b/debian/sylkserver.init old mode 100644 new mode 100755 index d903434..9fb7ca1 --- a/debian/sylkserver.init +++ b/debian/sylkserver.init @@ -1,62 +1,62 @@ #!/bin/sh -# + ### BEGIN INIT INFO # Provides: sylkserver # Required-Start: $syslog $network $local_fs $remote_fs $time # Required-Stop: $syslog $network $local_fs $remote_fs # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start the SylkServer # Description: Start the SylkServer ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin INSTALL_DIR="/usr/bin" RUNTIME_DIR="/run/sylkserver" SERVER="$INSTALL_DIR/sylk-server" PID="$RUNTIME_DIR/sylk-server.pid" OPTIONS="" NAME="sylk-server" DESC="SylkServer" test -f $SERVER || exit 0 . /lib/lsb/init-functions ulimit -c unlimited start() { log_daemon_msg "Starting $DESC: $NAME " start-stop-daemon --start --quiet --pidfile $PID \ --exec $SERVER -- $OPTIONS || log_progress_msg "already running" } stop () { log_daemon_msg "Stopping $DESC: $NAME " start-stop-daemon --stop --quiet --oknodo --retry=TERM/15/KILL/5 --pidfile $PID } case "$1" in start) start log_end_msg 0 ;; stop) stop log_end_msg 0 ;; restart|force-reload) stop start log_end_msg 0 ;; *) echo "Usage: /etc/init.d/$NAME {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0