[pkg-kolab] r250 - trunk/kolabd/debian
Achim Bohnet
ach at mpe.mpg.de
Mon Jan 30 22:48:12 UTC 2006
On Monday 30 January 2006 23:16, Noel Koethe wrote:
> Author: noel
> Date: 2006-01-30 22:16:55 +0000 (Mon, 30 Jan 2006)
> New Revision: 250
>
> Added:
> trunk/kolabd/debian/kolabd.init
> Log:
> add the kolab init script
>
> Added: trunk/kolabd/debian/kolabd.init
> ===================================================================
> --- trunk/kolabd/debian/kolabd.init 2006-01-30 18:28:06 UTC (rev 249)
> +++ trunk/kolabd/debian/kolabd.init 2006-01-30 22:16:55 UTC (rev 250)
> @@ -0,0 +1,51 @@
> +#!/bin/sh
> +#
> +# start/stop kolab server.
> +
> +if ! [ -x /usr/sbin/kolabd ]; then
> + exit 0
> +fi
> +
> +KOLABPID=/var/run/kolab.pid
> +
> +. /lib/lsb/init-functions
> +
> +case "$1" in
> + start)
> + echo "Starting Kolab daemons" "kolabd"
FWIW:
^-- -n
Or as an example in init-functions
...
# Sample usage:
# log_daemon_msg "Starting GNOME Login Manager" "gdm"
#
# On Debian, would output "Starting GNOME Login Manager: gdm"
# On Ubuntu, would output " * Starting GNOME Login Manager..."
#
# If the second argument is omitted, logging suitable for use with
# log_progress_msg() is used:
#
# log_daemon_msg "Starting remote filesystem services"
#
# On Debian, would output "Starting remote filesystem services:"
# On Ubuntu, would output " * Starting remote filesystem services..."
...
# log_daemon_msg "Starting remote file system services"
# log_progress_msg "nfsd"; start-stop-daemon --start --quiet nfsd
# log_progress_msg "mountd"; start-stop-daemon --start --quiet mountd
# log_progress_msg "ugidd"; start-stop-daemon --start --quiet ugidd
# log_end_msg 0
...
Achim
> +
> + if ! start-stop-daemon --start --quiet --oknodo --background --exec /usr/sbin/kolabd; then
> + log_end_msg 1
> + exit 1
> + fi
> +
> + log_end_msg 0
> + ;;
> + stop)
> + echo "Stopping Kolab daemons" "kolabd"
> +
> + start-stop-daemon --stop --quiet --pidfile $KOLABPID
> +
> + log_end_msg 0
> + ;;
> + reload)
> + echo "Reloading /etc/kolab/kolab.conf" "kolabd"
> +
> + start-stop-daemon --stop --signal HUP --pidfile $KOLABPID
> +
> + log_end_msg 0
> + ;;
> + restart|force-reload)
> + $0 stop
> + sleep 1
> + $0 start
> +
> + ;;
> + *)
> + echo "Usage: /etc/init.d/kolabd {start|stop|reload|force-reload|restart}"
> + exit 1
> + ;;
> +esac
> +
> +exit 0
> +
>
>
> _______________________________________________
> pkg-kolab-devel mailing list
> pkg-kolab-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/pkg-kolab-devel
>
>
--
To me vi is Zen. To use vi is to practice zen. Every command is
a koan. Profound to the user, unintelligible to the uninitiated.
You discover truth everytime you use it.
-- reddy at lion.austin.ibm.com
More information about the pkg-kolab-devel
mailing list