Add and rc.conf.d directory. If a config file for command X exists
(/etc/rc.conf.d/X), then it is sourced in addition of /etc/rc.conf This means that the base system will still use rc.conf, but that 3rd party scripts can use rc.conf.d
This commit is contained in:
parent
75748efda9
commit
5b8623bec6
@ -1,4 +1,4 @@
|
|||||||
# $NetBSD: NetBSD.dist,v 1.108 2000/05/12 18:12:55 thorpej Exp $
|
# $NetBSD: NetBSD.dist,v 1.109 2000/06/09 14:28:00 fvdl Exp $
|
||||||
# @(#)4.4BSD.dist 8.1 (Berkeley) 6/13/93
|
# @(#)4.4BSD.dist 8.1 (Berkeley) 6/13/93
|
||||||
|
|
||||||
/set type=dir uname=root gname=wheel mode=0755
|
/set type=dir uname=root gname=wheel mode=0755
|
||||||
@ -95,6 +95,11 @@ rc.d
|
|||||||
# ./etc/rc.d
|
# ./etc/rc.d
|
||||||
..
|
..
|
||||||
|
|
||||||
|
# ./etc/rc.conf.d
|
||||||
|
rc.conf.d
|
||||||
|
# ./etc/rc.conf.d
|
||||||
|
..
|
||||||
|
|
||||||
# ./etc/sliphome
|
# ./etc/sliphome
|
||||||
sliphome
|
sliphome
|
||||||
# ./etc/sliphome
|
# ./etc/sliphome
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# $NetBSD: rc.subr,v 1.19 2000/05/13 08:23:45 lukem Exp $
|
# $NetBSD: rc.subr,v 1.20 2000/06/09 14:27:57 fvdl Exp $
|
||||||
#
|
#
|
||||||
# Copyright (c) 1997-2000 The NetBSD Foundation, Inc.
|
# Copyright (c) 1997-2000 The NetBSD Foundation, Inc.
|
||||||
# All rights reserved.
|
# All rights reserved.
|
||||||
@ -449,7 +449,6 @@ run_rc_script()
|
|||||||
#
|
#
|
||||||
# load_rc_config
|
# load_rc_config
|
||||||
# Source in the configuration file for a given command.
|
# Source in the configuration file for a given command.
|
||||||
# Currently just uses /etc/rc.conf.
|
|
||||||
#
|
#
|
||||||
load_rc_config()
|
load_rc_config()
|
||||||
{
|
{
|
||||||
@ -459,6 +458,9 @@ load_rc_config()
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
. /etc/rc.conf
|
. /etc/rc.conf
|
||||||
|
if [ -f /etc/rc.conf.d/"$_command" ]; then
|
||||||
|
. /etc/rc.conf.d/"$_command"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user