diff options
| author | Shulhan <ms@kilabit.info> | 2022-04-20 11:41:11 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2022-04-20 11:41:11 +0700 |
| commit | d99356259a60ac0e2c345e60b3a6c92c3fb9d764 (patch) | |
| tree | 916ccaf7c1a640340d0b8b0d03fd03d616d5e502 /_scripts | |
| parent | 46f8ba922984a655c34954895aaf0234bf30e822 (diff) | |
| download | rescached-d99356259a60ac0e2c345e60b3a6c92c3fb9d764.tar.xz | |
all: move all installation files into directory _sys
Previously, all files required for installing rescached scattered in
different directories.
This changes move all files into single directory _sys with the
directory structure matched with target system.
Diffstat (limited to '_scripts')
| -rw-r--r-- | _scripts/info.kilabit.rescached.plist | 24 | ||||
| -rwxr-xr-x | _scripts/rescached.run | 84 | ||||
| -rw-r--r-- | _scripts/rescached.service | 17 |
3 files changed, 0 insertions, 125 deletions
diff --git a/_scripts/info.kilabit.rescached.plist b/_scripts/info.kilabit.rescached.plist deleted file mode 100644 index a8ba787..0000000 --- a/_scripts/info.kilabit.rescached.plist +++ /dev/null @@ -1,24 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> -<!-- SPDX-FileCopyrightText: 2020 M. Shulhan <ms@kilabit.info> --> -<!-- SPDX-License-Identifier: GPL-3.0-or-later --> -<plist version="1.0"> - <dict> - <key>Label</key> - <string>info.kilabit.rescached</string> - <key>ProgramArguments</key> - <array> - <string>/usr/local/bin/rescached</string> - <string>-config</string> - <string>/etc/rescached/rescached.cfg</string> - </array> - <key>RunAtLoad</key> - <true/> - <key>KeepAlive</key> - <true/> - <key>StandardOutPath</key> - <string>/var/log/rescached.log</string> - <key>StandardErrorPath</key> - <string>/var/log/rescached.error</string> - </dict> -</plist> diff --git a/_scripts/rescached.run b/_scripts/rescached.run deleted file mode 100755 index e9a602f..0000000 --- a/_scripts/rescached.run +++ /dev/null @@ -1,84 +0,0 @@ -#!/bin/sh -## SPDX-FileCopyrightText: 2018 M. Shulhan <ms@kilabit.info> -## SPDX-License-Identifier: GPL-3.0-or-later - -### BEGIN INIT INFO -# Provides: rescached -# Required-Start: $syslog $remote_fs -# Required-Stop: $syslog $remote_fs -# Default-Start: 3 5 -# Default-Stop: 0 1 2 6 -# Short-Description: resolver cache daemon. -# Description: resolver cache daemon. -### END INIT INFO - -RESCACHED_BIN=/usr/bin/rescached -RESCACHED_CFG=/etc/rescached/rescached.cfg - -# -# check if program exist. -# -test -x ${RESCACHED_BIN} || { - echo "Program '${RESCACHED_BIN}' not installed"; - if [ "$1" = "stop" ]; then - exit 0; - else - exit 5; - fi; -} - -# -# check if configuration file exist. -# -test -r ${RESCACHED_CFG} || { - echo "File '${RESCACHED_CFG}' not existing"; - if [ "$1" = "stop" ]; then - exit 0; - else - exit 6; - fi; -} - -case "$1" in -start) - echo -n "Starting rescached " - ${RESCACHED_BIN} ${RESCACHED_CFG} & - if test $? = 0; then - echo "[OK]"; - else - echo "[FAIL]"; - fi; - ;; - -stop) - echo -n "Shutting down rescached " - - killall ${RESCACHED_PID}; - - if test $? = 0; then - echo "[OK]"; - else - echo "[not running]"; - fi; - ;; - -restart) - $0 stop - $0 start - ;; - -status) - echo -n "Checking for service rescached " - RESCACHED_PS=`ps -ef | grep "rescached -config"` - if [[ "${RESCACHED_PS}" -ne "" ]]; then - echo "[running]"; - else - echo "[not running]"; - fi; - ;; - -*) - echo "Usage: $0 {start|stop|restart|status}" - exit 1 - ;; -esac diff --git a/_scripts/rescached.service b/_scripts/rescached.service deleted file mode 100644 index 8f86608..0000000 --- a/_scripts/rescached.service +++ /dev/null @@ -1,17 +0,0 @@ -## SPDX-FileCopyrightText: 2020 M. Shulhan <ms@kilabit.info> -## SPDX-License-Identifier: GPL-3.0-or-later - -[Unit] -Description=Resolver Cache Daemon -Wants=network-online.target nss-lookup.target -After=network.target network-online.target -Before=nss-lookup.target - -[Service] -Type=simple -ExecStart=/usr/bin/rescached -config /etc/rescached/rescached.cfg -Restart=on-failure -StandardError=journal - -[Install] -WantedBy=multi-user.target |
