xref: /freebsd/libexec/rc/rc.d/local (revision f99f0ee14e3af81c23150a6a340259ca8a33d01a)
1#!/bin/sh
2#
3#
4
5# PROVIDE: local
6# REQUIRE: DAEMON
7# BEFORE:  LOGIN
8# KEYWORD: shutdown
9
10. /etc/rc.subr
11
12name="local"
13desc="Run /etc/rc.local and /etc/rc.shutdown.local"
14start_cmd="local_start"
15stop_cmd="local_stop"
16
17local_start()
18{
19	if [ -f /etc/rc.local ]; then
20		startmsg -n 'Starting local daemons:'
21		. /etc/rc.local
22		startmsg '.'
23	fi
24}
25
26local_stop()
27{
28	if [ -f /etc/rc.shutdown.local ]; then
29		echo -n 'Shutting down local daemons:'
30		. /etc/rc.shutdown.local
31		echo '.'
32	fi
33}
34
35load_rc_config $name
36
37# doesn't make sense to run in a svcj: it may contain everything
38local_svcj="NO"
39
40run_rc_command "$1"
41