Merge branch 'master' of github.com:fbt/watchman-services
This commit is contained in:
commit
b4d3135878
24
init.d/nginx
Executable file
24
init.d/nginx
Executable file
|
@ -0,0 +1,24 @@
|
||||||
|
#!/usr/bin/env watchman
|
||||||
|
|
||||||
|
service_command='/usr/bin/nginx'
|
||||||
|
service_pidfile='/run/nginx.pid'
|
||||||
|
|
||||||
|
nginx.test_config() { "$service_command" -tq; }
|
||||||
|
|
||||||
|
reload() {
|
||||||
|
nginx.test_config || {
|
||||||
|
watchman.err "Nginx config test failed, not reloading."
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
watchman.reload
|
||||||
|
}
|
||||||
|
|
||||||
|
restart() {
|
||||||
|
nginx.test_config || {
|
||||||
|
watchman.err "Nginx config test failed, not restarting."
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
stop; start
|
||||||
|
}
|
4
init.d/ntpd → init.d/ntp
Executable file → Normal file
4
init.d/ntpd → init.d/ntp
Executable file → Normal file
|
@ -1,7 +1,5 @@
|
||||||
#!/usr/bin/env watchman
|
#!/usr/bin/env watchman
|
||||||
|
|
||||||
cfg_ntpd_config='/etc/ntp.conf'
|
|
||||||
|
|
||||||
service_respawn='true'
|
service_respawn='true'
|
||||||
service_command='/bin/ntpd'
|
service_command='/bin/ntpd'
|
||||||
service_args="-c $cfg_ntpd_config -n"
|
service_args='-n'
|
5
init.d/openntpd
Executable file
5
init.d/openntpd
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/usr/bin/env watchman
|
||||||
|
|
||||||
|
service_respawn='true'
|
||||||
|
service_command='/bin/ntpd'
|
||||||
|
service_args='-d'
|
Loading…
Reference in New Issue
Block a user