/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to init.d-mandos

  • Committer: Teddy Hogeborn
  • Date: 2013-10-27 00:45:08 UTC
  • Revision ID: teddy@recompile.se-20131027004508-puplag2stsmnkfig
Fix fallback to /var/run if /run does not exist for Makefile.

* Makefile (purge-server): Also purge the pid file in the old
                           location, if any.

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
NAME=mandos
24
24
DAEMON=/usr/sbin/$NAME
25
25
DAEMON_ARGS=""
26
 
PIDFILE=/var/run/$NAME.pid
 
26
if [ -d /run/. ]; then
 
27
    PIDFILE=/run/$NAME.pid
 
28
else
 
29
    PIDFILE=/var/run/$NAME.pid
 
30
fi
27
31
SCRIPTNAME=/etc/init.d/$NAME
28
32
 
29
33
# Exit if the package is not installed
149
153
                ;;
150
154
        esac
151
155
        ;;
 
156
  status)
 
157
        status_of_proc "$DAEMON" "$NAME" -p "$PIDFILE"
 
158
        ;;
152
159
  *)
153
160
        #echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2
154
161
        echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2