ssm-services/init.d/sysctl

24 lines
379 B
Plaintext
Raw Normal View History

2014-03-01 18:34:13 +00:00
#!/usr/bin/env watchman
2015-09-04 13:47:37 +00:00
unset reload
2014-03-01 18:34:13 +00:00
service_type='oneshot'
2015-06-18 09:38:49 +00:00
service_command='/usr/bin/sysctl'
2014-07-03 07:05:52 +00:00
2015-09-04 13:47:37 +00:00
pre_start() {
for i in /etc/sysctl.conf /etc/sysctl.d/* /usr/lib/sysctl.d/*; do
[[ -f "$i" ]] && {
sysctl_config_files+=( "$i" )
}
done
service_args=( -p "${sysctl_config_files[@]}" )
}
start() {
if ! [[ "$sysctl_config_files" ]]; then
return 0
fi
watchman.start
}