service: respect nojailvnet keyword
In the 761d2bb5b9e70cf30f9c2dac62a47a2d2593e83f we added nojailvnet keyword. The nojailvnet keyword is used to skip startup scripts in jails that are run without VNET. The service.sh was omitted in this commit. The service.sh even documents that this is the same code as in rc - so lets reflect that. Submitted by: Adam Wołk <a.wolk@fudosecurity.com> Sponsored by: Fudo Security
This commit is contained in:
parent
94f2e42f5e
commit
05b267e232
@ -83,6 +83,9 @@ if [ -n "$RESTART" ]; then
|
||||
skip="-s nostart"
|
||||
if [ `/sbin/sysctl -n security.jail.jailed` -eq 1 ]; then
|
||||
skip="$skip -s nojail"
|
||||
if [ `/sbin/sysctl -n security.jail.vnet` -ne 1 ]; then
|
||||
skip="$skip -s nojailvnet"
|
||||
fi
|
||||
fi
|
||||
[ -n "$local_startup" ] && find_local_scripts_new
|
||||
files=`rcorder ${skip} ${local_rc} 2>/dev/null`
|
||||
@ -113,6 +116,9 @@ if [ -n "$ENABLED" -o -n "$RCORDER" ]; then
|
||||
skip="-s nostart"
|
||||
if [ `/sbin/sysctl -n security.jail.jailed` -eq 1 ]; then
|
||||
skip="$skip -s nojail"
|
||||
if [ `/sbin/sysctl -n security.jail.vnet` -ne 1 ]; then
|
||||
skip="$skip -s nojailvnet"
|
||||
fi
|
||||
fi
|
||||
[ -n "$local_startup" ] && find_local_scripts_new
|
||||
files=`rcorder ${skip} /etc/rc.d/* ${local_rc} 2>/dev/null`
|
||||
|
Loading…
x
Reference in New Issue
Block a user