diff options
| author | Jan Tuomi <jan@jantuomi.fi> | 2025-09-29 00:53:24 +0200 |
|---|---|---|
| committer | Jan Tuomi <jan@jantuomi.fi> | 2025-09-29 00:53:24 +0200 |
| commit | 7c5eae9294994e59a5176eba21093ecd6cdfcf63 (patch) | |
| tree | a3d7d0a34d6e4b9a773cd85b99afc9eca5b5bb9c /templates/usr_local_etc_rc.d_do_dyndns.j2 | |
| parent | cc1b02f99e457d2a5a440698e9bae1ca30f408e1 (diff) | |
Improve jails
Diffstat (limited to 'templates/usr_local_etc_rc.d_do_dyndns.j2')
| -rw-r--r-- | templates/usr_local_etc_rc.d_do_dyndns.j2 | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/templates/usr_local_etc_rc.d_do_dyndns.j2 b/templates/usr_local_etc_rc.d_do_dyndns.j2 deleted file mode 100644 index 6c4c18e..0000000 --- a/templates/usr_local_etc_rc.d_do_dyndns.j2 +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh -# -# PROVIDE: do_dyndns -# REQUIRE: NETWORKING -# KEYWORD: shutdown - -. /etc/rc.subr - -name="do_dyndns" -rcvar=do_dyndns_enable - -extra_commands="status" -rcvars="do_dyndns_enable do_dyndns_domain do_dyndns_hostname do_dyndns_if4 do_dyndns_interval do_dyndns_auth_file" -stop_cmd="do_dyndns_stop" - -load_rc_config $name - -: "${do_dyndns_enable:=NO}" -: "${do_dyndns_interval:=1m}" -: "${do_dyndns_hostname:=@}" -: "${do_dyndns_auth_file:=/usr/local/etc/do_dyndns_auth}" - -pidfile="/var/run/${name}.pid" -logfile="/var/log/${name}" - -command="/usr/sbin/daemon" -command_args="-cfr -P ${pidfile} -o ${logfile} /bin/sh -c ' - export PATH=\"/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin\" - export DO_DYNDNS_DOMAIN=\"${do_dyndns_domain}\" - export DO_DYNDNS_HOSTNAME=\"${do_dyndns_hostname}\" - export DO_DYNDNS_IF4=\"${do_dyndns_if4}\" - export DO_DYNDNS_INTERVAL=\"${do_dyndns_interval}\" - export DO_DYNDNS_AUTH_FILE=\"${do_dyndns_auth_file}\" - - exec /usr/local/bin/do_dyndns.sh -'" - -do_dyndns_stop() { - echo "Stopping ${name} with SIGINT..." - if [ -f "${pidfile}" ]; then - kill -INT "$(cat "${pidfile}")" - sleep 5 - if kill -0 "$(cat "${pidfile}")" 2>/dev/null; then - echo "Process didn't exit, sending SIGKILL..." - kill -KILL "$(cat "${pidfile}")" - fi - rm -f "${pidfile}" - else - echo "${name}: no pidfile found" - fi -} - -run_rc_command "$1" |
