/[pdpsoft]/nl.nikhef.pdp.fetchcrl/trunk/fetch-crl-boot.init
ViewVC logotype

Contents of /nl.nikhef.pdp.fetchcrl/trunk/fetch-crl-boot.init

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1878 - (show annotations) (download)
Tue Aug 10 07:03:43 2010 UTC (11 years, 2 months ago) by davidg
Original Path: trunk/fetchcrl/fetch-crl-boot.init
File size: 1428 byte(s)
upgrade to RC4, see changelog

1 #!/bin/sh
2 #
3 # fetch-crl-boot This shell script trigger a run of fetch-crl at boot time
4 #
5 # chkconfig: - 65 01
6 #
7 # description: Run of fetch-crl, a crl updater, on boot up
8 # processname: fetch-crl
9 # config: /etc/fetch-crl.conf
10 # config: /etc/sysconfig/fetch-crl
11 #
12
13 # fetch-crl-boot must run after the start of xinetd and afs, since the URLs
14 # may point to files on an AFS file system or to xinetd-based service URLs
15
16 # source function library
17 . /etc/rc.d/init.d/functions
18
19 # source any environment settings, e.g. for HTTP proxies
20 [ -f /etc/sysconfig/fetch-crl ] && . /etc/sysconfig/fetch-crl
21
22 lockfile=/var/lock/subsys/fetch-crl-boot
23
24 RETVAL=0
25
26 start() {
27 action $"Running fetch-crl on boot: " /usr/sbin/fetch-crl -q
28 RETVAL=$?
29 [ "$RETVAL" = 0 ] && touch $lockfile
30 }
31
32 stop() {
33 RETVAL=0
34 [ "$RETVAL" = 0 ] && rm -f $lockfile
35 }
36
37 case "$1" in
38 start)
39 start
40 ;;
41 stop)
42 stop
43 ;;
44 restart|force-reload)
45 $0 stop
46 $0 start
47 ;;
48 condrestart)
49 [ -f $lockfile ] && {
50 $0 stop
51 $0 start
52 }
53 ;;
54 reload)
55 ;;
56 status)
57 if [ -f $lockfile ] ; then
58 echo -n $"fetch-crl-boot lockfile present" && success
59 RETVAL=0
60 else
61 echo -n $"fetch-crl-boot lockfile missing" && failure
62 RETVAL=1
63 fi
64 echo
65 ;;
66 *)
67 echo $"Usage: $0 {start|stop|status|restart|reload|force-reload|condrestart}"
68 exit 1
69 esac
70
71 exit $RETVAL

grid.support@nikhef.nl
ViewVC Help
Powered by ViewVC 1.1.28