/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: 2012-05-07 20:46:51 UTC
  • Revision ID: teddy@recompile.se-20120507204651-qx5o5ztwmau54mh4
* mandos-monitor: Speedup: Use properties from D-Bus
                  GetAllClientsWithProperties() call.  Also use
                  super() properly - only use keyword arguments and
                  strip them off as "kwargs" is passed on.
  (MandosClientPropertyCache.__init__): Take new "properties"
                                        argument; use it to skip
                                        calling D-Bus GetAll() method.
                                        Call super().  Bind self._
  (MandosClientPropertyCache._property_changed): New helper function.
  (MandosClientPropertyCache.property_changed): Changed to take
                                                keyword arguments.
  (MandosClientPropertyCache.delete): Bug fix: Don't call
                                      super().__init__().
  (MandosClientWidget.__init__): Don't take *args.  Strip used keyword
                                 arguments before calling super().
  (MandosClientWidget.property_changed): Removed dead code.
  (MandosClientWidget.delete): Don't take *args.
  (MandosClientWidget.property_changed): Don't take "value" argument,
                                         since it is not used.
  (ConstrainedListBox.keypress): Take *args, **kwargs and pass them on
                                 to super().

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#! /bin/sh
2
2
### BEGIN INIT INFO
3
3
# Provides:          mandos
4
 
# Required-Start:    $remote_fs $syslog avahi-daemon
5
 
# Required-Stop:     $remote_fs $syslog avahi-daemon
 
4
# Required-Start:    $remote_fs $syslog avahi
 
5
# Required-Stop:     $remote_fs $syslog avahi
6
6
# Default-Start:     2 3 4 5
7
7
# Default-Stop:      0 1 6
8
8
# Short-Description: Mandos server
9
 
# Description:       Server of encrypted passwords to Mandos clients
 
9
# Description:       Gives encrypted passwords to Mandos clients
10
10
### END INIT INFO
11
11
 
12
12
# Author: Teddy Hogeborn <teddy@recompile.se>
23
23
NAME=mandos
24
24
DAEMON=/usr/sbin/$NAME
25
25
DAEMON_ARGS=""
26
 
if [ -d /run/. ]; then
27
 
    PIDFILE=/run/$NAME.pid
28
 
else
29
 
    PIDFILE=/var/run/$NAME.pid
30
 
fi
 
26
PIDFILE=/var/run/$NAME.pid
31
27
SCRIPTNAME=/etc/init.d/$NAME
32
28
 
33
29
# Exit if the package is not installed
44
40
. /lib/init/vars.sh
45
41
 
46
42
# Define LSB log_* functions.
47
 
# Depend on lsb-base (>= 3.2-14) to ensure that this file is present
48
 
# and status_of_proc is working.
 
43
# Depend on lsb-base (>= 3.0-6) to ensure that this file is present.
49
44
. /lib/lsb/init-functions
50
45
 
51
46
#
123
118
                2) [ "$VERBOSE" != no ] && log_end_msg 1 ;;
124
119
        esac
125
120
        ;;
126
 
  status)
127
 
        status_of_proc "$DAEMON" "$NAME" -p "$PIDFILE" && exit 0 || exit $?
128
 
        ;;
129
121
  #reload|force-reload)
130
122
        #
131
123
        # If do_reload() is not implemented then leave this commented out
152
144
                esac
153
145
                ;;
154
146
          *)
155
 
                # Failed to stop
 
147
                # Failed to stop
156
148
                log_end_msg 1
157
149
                ;;
158
150
        esac
159
151
        ;;
160
152
  *)
161
153
        #echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2
162
 
        echo "Usage: $SCRIPTNAME {start|stop|status|restart|force-reload}" >&2
 
154
        echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
163
155
        exit 3
164
156
        ;;
165
157
esac