![]() System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, Directory : /etc/rc3.d/ |
Upload File : |
#! /bin/sh ### BEGIN INIT INFO # Provides: tinyproxy # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Tinyproxy HTTP proxy # Description: Start, stop or reload tinyproxy. ### END INIT INFO # # Tinyproxy init.d script # Ed Boraas 1999 # PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin CONFIG=/etc/tinyproxy/tinyproxy.conf DAEMON=/usr/bin/tinyproxy DESC="Tinyproxy lightweight HTTP proxy daemon" FLAGS= NAME=tinyproxy if [ -r /etc/default/tinyproxy ]; then . /etc/default/tinyproxy fi FLAGS="$FLAGS -c $CONFIG" test -f $DAEMON || exit 0 . /lib/lsb/init-functions set -e # assert pidfile directory and permissions if [ "$1" != "stop" ]; then if [ -f "$CONFIG" ]; then USER=$(grep -i '^User[[:space:]]' "$CONFIG" | awk '{print $2}') GROUP=$(grep -i '^Group[[:space:]]' "$CONFIG" | awk '{print $2}') PIDFILE=$(grep -i '^PidFile[[:space:]]' "$CONFIG" | awk '{print $2}' |\ sed -e 's/"//g') if [ -n "$PIDFILE" ];then PIDDIR=$(dirname "$PIDFILE") fi if [ -n "$PIDDIR" -a "$PIDDIR" != "/run" ]; then if [ ! -d "$PIDDIR" ]; then mkdir "$PIDDIR" fi if [ -n "$USER" ]; then chown "$USER" "$PIDDIR" fi if [ -n "$GROUP" ]; then chown ":$GROUP" "$PIDDIR" fi fi fi fi case "$1" in start) echo -n "Starting $DESC: " start-stop-daemon --start --quiet -o --exec $DAEMON -- $FLAGS echo "$NAME." ;; stop) echo -n "Stopping $DESC: " start-stop-daemon --stop --quiet -o --exec $DAEMON echo "$NAME." ;; reload|force-reload) echo "Reloading $NAME configuration files." start-stop-daemon --stop --signal 1 --quiet -o --exec $DAEMON ;; restart) echo -n "Restarting $DESC: " start-stop-daemon --stop --quiet -o --exec $DAEMON sleep 1 start-stop-daemon --start --quiet -o --exec $DAEMON -- $FLAGS echo "$NAME." ;; *) N=/etc/init.d/$NAME echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 exit 1 ;; esac exit 0