Skip to content

Commit f3c699e

Browse files
g-papeericonr
authored andcommitted
* change default directory for services from /var/service/ to /service/.
1 parent fd49d8f commit f3c699e

File tree

22 files changed

+45
-44
lines changed

22 files changed

+45
-44
lines changed

doc/benefits.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ <h1>runit - benefits</h1>
149149
Stage 2 is packaging friendly:
150150
all a software package that provides a service needs to do is to include
151151
a <i>service directory</i> in the package, and to provide a symbolic link
152-
to this directory in <tt>/var/service/</tt>.
152+
to this directory in <tt>/service/</tt>.
153153
The service will be started within five seconds, and automatically at boot
154154
time.
155155
The package's install and update scripts can use the reliable control

doc/faq.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -216,12 +216,12 @@ <h1>runit - Frequently asked questions</h1>
216216
up and runs the service by default?
217217
<p>
218218
Answer:
219-
Create a symbolic link in <tt>/var/service/</tt> pointing to the service
219+
Create a symbolic link in <tt>/service/</tt> pointing to the service
220220
directory, runit will pick up the service within the next five seconds,
221221
and automatically start it on system boot.
222222
E.g.:
223223
<pre>
224-
# ln -s /etc/sv/getty-2 /var/service/
224+
# ln -s /etc/sv/getty-2 /service/
225225
</pre>
226226

227227
<hr>
@@ -283,13 +283,13 @@ <h1>runit - Frequently asked questions</h1>
283283
How do I tell runit?
284284
<p>
285285
Answer:
286-
Remove the symbolic link in <tt>/var/service/</tt> pointing to the service
286+
Remove the symbolic link in <tt>/service/</tt> pointing to the service
287287
directory, runit recognizes the removed service within the next five
288288
seconds, then stops the service, the optional log service, and finally the
289289
supervisor process.
290290
E.g.:
291291
<pre>
292-
# rm /var/service/getty-2
292+
# rm /service/getty-2
293293
</pre>
294294

295295
<hr>

doc/replaceinit.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ <h3>Step 3: The getties</h3>
5252
needed), and tell <a href="runsvdir.8.html">runsvdir</a> about the getty-5
5353
<i>service</i>:
5454
<pre>
55-
# mkdir -p /var/service
56-
# ln -s /etc/sv/getty-5 /var/service/
55+
# mkdir -p /service
56+
# ln -s /etc/sv/getty-5 /service/
5757
</pre>
5858
Start <i>runit</i>'s stage 2 for testing:
5959
<pre>
@@ -177,8 +177,8 @@ <h3>Step 3: The getties</h3>
177177
and tell <a href="runsvdir.8.html">runsvdir</a> about the <tt>getty-5</tt>
178178
<i>service</i>:
179179
<pre>
180-
# mkdir -p /var/service
181-
# ln -s /etc/sv/getty-5 /var/service/
180+
# mkdir -p /service
181+
# ln -s /etc/sv/getty-5 /service/
182182
</pre>
183183
Start <i>runit</i>'s stage 2 for testing:
184184
<pre>

doc/runlevels.html

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@ <h1>runit - runlevels</h1>
2525
# ln -s /etc/sv/getty-5 /etc/runit/runsvdir/single/
2626
# ln -s default /etc/runit/runsvdir/current
2727
</pre>
28-
Copy the contents of <tt>/var/service/</tt> to
29-
<tt>/etc/runit/runsvdir/current/</tt> and replace <tt>/var/service/</tt>
28+
Copy the contents of <tt>/service/</tt> to
29+
<tt>/etc/runit/runsvdir/current/</tt> and replace <tt>/service/</tt>
3030
with a symbolic link:
3131
<pre>
32-
# cp -pR /var/service/* /etc/runit/runsvdir/current/
33-
# mv -f /var/service /var/service.old && \
34-
ln -s /etc/runit/runsvdir/current /var/service
32+
# cp -pR /service/* /etc/runit/runsvdir/current/
33+
# mv -f /service /service.old && \
34+
ln -s /etc/runit/runsvdir/current /service
3535
</pre>
3636
You have now created two runlevels: <tt>default</tt> and <tt>single</tt>.
3737
The <tt>current</tt> runlevel is <tt>default</tt>.
38-
It is safe to remove <tt>/var/service.old/</tt> if you don't need it anymore.
38+
It is safe to remove <tt>/service.old/</tt> if you don't need it anymore.
3939
<p>
4040
Finally edit <tt>/etc/runit/2</tt> to set the <tt>default</tt> runlevel when
4141
stage 2 starts:
@@ -47,7 +47,7 @@ <h1>runit - runlevels</h1>
4747
<b>runsvchdir default &gt;/dev/null</b>
4848

4949
exec env - PATH=$PATH \
50-
runsvdir /var/service 'log: ...........................................................................................................................................................................................................................................................................................................................................................................................................'
50+
runsvdir /service 'log: ...........................................................................................................................................................................................................................................................................................................................................................................................................'
5151
</pre>
5252
<hr>
5353
<a name="switch"><h3>Switching runlevels</h3></a>

doc/runscripts.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ <h3><a name="fam">A <tt>fam</tt> run script</a></h3>
390390
<pre>
391391
#!/bin/sh
392392
exec 2&gt;&amp;1
393-
sv start /var/service/portmap || exit 1
393+
sv start /service/portmap || exit 1
394394
exec famd -T 0 -f
395395
</pre>
396396
<hr>

doc/runsv.8.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,9 @@ <h2><a name='sect3'>Control</a></h2>
108108
<p>
109109
Example:
110110
to send a TERM signal to the socklog-unix service, either do # sv term
111-
/var/service/socklog-unix<br>
111+
/service/socklog-unix<br>
112112
or<br>
113-
# printf t &gt;/var/service/socklog-unix/supervise/control<br>
113+
# printf t &gt;/service/socklog-unix/supervise/control<br>
114114
<p>
115115
<i><b>printf</b>(1)</i> usually blocks if no <b>runsv</b> process is running in the service
116116
directory.

doc/runsvchdir.8.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ <h2><a name='sect2'>Description</a></h2>
2020
<b>runsvchdir</b> switches to the directory <i>/etc/runit/runsvdir/</i>,
2121
copies <i>current</i> to <i>previous</i>, and replaces <i>current</i> with a symlink pointing
2222
to <i>dir</i>. <p>
23-
Normally <i>/var/service</i> is a symlink to <i>current</i>, and <i><b>runsvdir</b>(8)</i>
24-
is running <i>/var/service/</i>.
23+
Normally <i>/service</i> is a symlink to <i>current</i>, and <i><b>runsvdir</b>(8)</i>
24+
is running <i>/service/</i>.
2525
<h2><a name='sect3'>Exit Codes</a></h2>
2626
<b>runsvchdir</b> prints an error message and
2727
exits 111 on error. <b>runsvchdir</b> exits 0 on success.

doc/sv.8.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ <h2><a name='sect2'>Description</a></h2>
2121
<i>services</i> consists of one or more arguments,
2222
each argument naming a directory <i>service</i> used by <i><b>runsv</b>(8)</i>. If <i>service</i> doesn&rsquo;t
2323
start with a dot or slash, it is searched in the default services directory
24-
<i>/var/service/</i>, otherwise relative to the current directory. <p>
24+
<i>/service/</i>, otherwise relative to the current directory. <p>
2525
<i>command</i> is one
2626
of up, down, status, once, pause, cont, hup, alarm, interrupt, 1, 2, term,
2727
kill, or exit, or start, stop, restart, shutdown, force-stop, force-reload,
@@ -157,7 +157,7 @@ <h2><a name='sect7'>Environment</a></h2>
157157

158158
<dt><b>SVDIR</b> </dt>
159159
<dd>The environment variable $SVDIR overrides the
160-
default services directory <i>/var/service/</i>. </dd>
160+
default services directory <i>/service/</i>. </dd>
161161

162162
<dt><b>SVWAIT</b> </dt>
163163
<dd>The environment variable

doc/useinit.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ <h1>runit - use with traditional init</h1>
2121
<p>
2222
In any case, you first need to copy the <i>stage 2</i> script to
2323
<tt>/sbin/runsvdir-start</tt>, and create the services directory
24-
<tt>/var/service/</tt>:
24+
<tt>/service/</tt>:
2525
<pre>
2626
# install -m0750 /package/admin/runit/etc/2 /sbin/runsvdir-start
27-
# mkdir -p /var/service
27+
# mkdir -p /service
2828
</pre>
2929
<hr>
3030
<a href="#sysv">How to use with sysvinit and inittab</a><br>

doc/utmpset.8.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ <h2><a name='sect2'>Description</a></h2>
2323
other services. <p>
2424
To enable local login accounting, add <b>utmpset</b> to the <i><b>getty</b>(8)</i>
2525
<i>finish</i> scripts, e.g.: <p>
26-
$ cat /var/service/getty-5/finish<br>
26+
$ cat /service/getty-5/finish<br>
2727
#!/bin/sh<br>
2828
exec utmpset -w tty5<br>
2929
$<br>

0 commit comments

Comments
 (0)