/[smeserver]/rpms/e-smith-runit/sme10/e-smith-runit-2.6.0-bz9692-cleanup.patch
ViewVC logotype

Contents of /rpms/e-smith-runit/sme10/e-smith-runit-2.6.0-bz9692-cleanup.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Tue Mar 16 19:53:36 2021 UTC (3 years, 7 months ago) by jpp
Branch: MAIN
CVS Tags: e-smith-runit-2_6_0-12_el7_sme, e-smith-runit-2_6_0-11_el7_sme, HEAD
Error occurred while calculating annotation data.
* Tue Mar 16 2021 Jean-Philippe Pialasse <tests@pialasse.com> 2.6.0-11.sme
- cleanup of /etc/rc.d [SME: 9692]

1 diff -Nur --no-dereference e-smith-runit-2.6.0.old/root/etc/rc.d/init.d/daemontools e-smith-runit-2.6.0/root/etc/rc.d/init.d/daemontools
2 --- e-smith-runit-2.6.0.old/root/etc/rc.d/init.d/daemontools 2021-03-16 15:12:25.293000000 -0400
3 +++ e-smith-runit-2.6.0/root/etc/rc.d/init.d/daemontools 1969-12-31 19:00:00.000000000 -0500
4 @@ -1,138 +0,0 @@
5 -#!/bin/sh
6 -
7 -###########################################################################
8 -#
9 -# System V style init script.
10 -# Relies on runit utilities to do the real work.
11 -# It is assumed that init scripts will be linked to this script.
12 -#
13 -###########################################################################
14 -
15 -# Determine the service name and its service directory from $0
16 -
17 -prog=$(/bin/basename $0 | sed -e 's/^[SK][0-9][0-9]*//')
18 -SERVICE_DIR=/service/$prog
19 -
20 -###########################################################################
21 -
22 -# Source in the RedHat initscripts functions
23 -SYSTEMCTL_SKIP_REDIRECT=1
24 -. /etc/rc.d/init.d/functions
25 -
26 -# The maximum amount of time to wait for a process to shut down, in seconds.
27 -SVWAIT=60
28 -
29 -start()
30 -{
31 - /bin/echo -n $"Starting $prog:"
32 - dirs=$1
33 - if [ -d $1/log ]; then
34 - dirs="$1/log $1"
35 - fi
36 - /usr/bin/sv u $dirs > /dev/null
37 - if [ $? -ne 0 ]; then
38 - failure "Starting $prog"
39 - else
40 - success "Starting $prog"
41 - fi
42 - /bin/echo
43 -}
44 -
45 -stop()
46 -{
47 - /bin/echo -n $"Stopping $prog:"
48 - /usr/bin/sv stop $1 > /dev/null
49 - if [ $? -ne 0 ]; then
50 - failure "Stopping $prog"
51 - else
52 - success "Stopping $prog"
53 - fi
54 - /bin/echo
55 -}
56 -
57 -# This function not only shuts the service down, but removes the /service
58 -# symlink and shuts down the logger. This should only be used during an
59 -# uninstall of the service in question.
60 -svdisable()
61 -{
62 - /bin/echo -n $"Disabling $prog:"
63 - stop $1
64 - cd $1 && rm -f $1
65 - dirs=.
66 - if [ -e log ]; then
67 - dirs="$dirs ./log"
68 - fi
69 - /usr/bin/sv d $dirs
70 - /usr/bin/sv x $dirs
71 - if [ $? -ne 0 ]; then
72 - failure "Disabling $prog"
73 - else
74 - success "Disabling $prog"
75 - fi
76 - /bin/echo
77 -}
78 -
79 -case $1 in
80 -
81 - restart)
82 - action "Restarting $prog" /usr/bin/sv t $SERVICE_DIR
83 - /usr/bin/sv u $SERVICE_DIR
84 - ;;
85 -
86 - sigalrm)
87 - action "Sending ALRM signal to $prog" /usr/bin/sv a $SERVICE_DIR
88 - ;;
89 -
90 - sigcont)
91 - action "Sending CONT signal to $prog" /usr/bin/sv c $SERVICE_DIR
92 - ;;
93 -
94 - sighup)
95 - action "Sending HUP signal to $prog" /usr/bin/sv h $SERVICE_DIR
96 - ;;
97 -
98 - sigusr1)
99 - action "Sending USR1 signal to $prog" /usr/bin/sv 1 $SERVICE_DIR
100 - ;;
101 -
102 - sigusr2)
103 - action "Sending USR2 signal to $prog" /usr/bin/sv 2 $SERVICE_DIR
104 - ;;
105 -
106 - sigint)
107 - action "Sending INT signal to $prog" /usr/bin/sv i $SERVICE_DIR
108 - ;;
109 -
110 - sigkill)
111 - action "Sending KILL signal to $prog" /usr/bin/sv k $SERVICE_DIR
112 - ;;
113 -
114 - sigstop)
115 - action "Sending STOP signal to $prog" /usr/bin/sv p $SERVICE_DIR
116 - ;;
117 -
118 - sigterm|condrestart)
119 - action "Sending TERM signal to $prog" /usr/bin/sv t $SERVICE_DIR
120 - ;;
121 -
122 - status)
123 - /usr/bin/sv status $SERVICE_DIR
124 - ;;
125 -
126 - start)
127 - start $SERVICE_DIR
128 - ;;
129 -
130 - stop)
131 - stop $SERVICE_DIR
132 - ;;
133 -
134 - svdisable)
135 - svdisable $SERVICE_DIR
136 - ;;
137 -
138 - *)
139 - echo $"usage: $0 {start|stop|restart|status|sigalrm|sigcont|sighup|sigint|sigkill|sigstop|sigterm|condrestart|sigusr1|sigusr2|svdisable}"
140 - ;;
141 -
142 -esac

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed