blob: e8fab14e024059ad7de2a500741a0ffc915d5bc1 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#!/bin/sh
#
# $FreeBSD$
#
# PROVIDE: afsserver
# REQUIRE: NETWORKING
# KEYWORD: shutdown
#
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
# afsserver_enable (bool): Set to NO by default.
# Set it to YES to enable AFS server activities.
. /etc/rc.subr
name="afsserver"
rcvar="afsserver_enable"
command="%%PREFIX%%/sbin/bosserver"
stop_precmd="afsserver_prestop"
vicedir="%%PREFIX%%/etc/openafs/server"
required_files="${vicedir}/CellServDB ${vicedir}/KeyFile ${vicedir}/ThisCell ${vicedir}/UserList"
load_rc_config "$name"
: ${afsserver_enable:="NO"}
afsserver_prestop()
{
%%PREFIX%%/bin/bos shutdown -localauth -server localhost
}
run_rc_command "$1"
|