From 5b3461d94783034b4262fd59d2bcbe97ab4acccc Mon Sep 17 00:00:00 2001 From: Shivaram Lingamneni Date: Sun, 17 Jan 2021 21:10:50 -0500 Subject: [PATCH] Destroyed debian (markdown) --- debian.md | 102 ------------------------------------------------------ 1 file changed, 102 deletions(-) delete mode 100644 debian.md diff --git a/debian.md b/debian.md deleted file mode 100644 index 05fcaef..0000000 --- a/debian.md +++ /dev/null @@ -1,102 +0,0 @@ -```sh -#!/bin/sh -# -# https://github.com/oragono/oragono -# -# this file based on https://github.com/jirihnidek/daemon -# -# For install oragono as service in Debian/Ubuntu -# -# Install(unzip) oragono into /opt/oragono directory, and do installation instructors of oragono -# Copy oragono.init file into /etc/init.d -# -# /etc/init.d/oragono.init -# chmod +x oragono.init -# service oragono.init start -# -# ref: -# https://serverfault.com/questions/135859/is-there-a-standard-way-to-make-daemon-in-debian -# https://stackoverflow.com/questions/8124345/call-to-daemon-in-a-etc-init-d-script-is-blocking-not-running-in-background -# http://big-elephants.com/2013-01/writing-your-own-init-scripts/ -# https://chris-lamb.co.uk/posts/start-stop-daemon-exec-vs-startas -# - -### BEGIN INIT INFO -# Provides: oragono -# Required-Start: $rsyslog -# Required-Stop: -# Should-Start: -# Should-Stop: -# Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 -# Short-Description: start/stop of Oragono -# Description: Oragono irc server -### END INIT INFO - -# Source function library. -. /lib/lsb/init-functions - -prog="oragono" -app_dir="/opt/$prog" -app="$app_dir/$prog" #no need to change -conf_file="/opt/$prog/ircd.yaml" -options="run --conf $conf_file --quiet" -lock_file="/var/lock/subsys/$prog" -pid_file="/var/run/$prog.pid" -log_file="/var/log/$prog.log" -proguser=root - -[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog - -start() { - [ -x $exec ] || exit 5 - echo -n $"Starting $prog:\n" - start-stop-daemon --start --quiet --oknodo --background -m --pidfile $pid_file --chdir $app_dir --exec $app -- $options - RETVAL=$? - return $RETVAL -} - -stop() { - echo -n $"Stopping $prog:\n" - start-stop-daemon --stop --quiet --oknodo --pidfile $pid_file - RETVAL=$? - return $RETVAL -} - -restart() { - stop - start -} - -rh_status() { -#not fixed yet - status $prog -} - -rh_status_q() { - rh_status >/dev/null 2>&1 -} - -case "$1" in - start) - #rh_status_q && exit 0 - $1 - ;; - stop) - #rh_status_q || exit 0 - $1 - ;; - restart) - $1 - ;; - status) -#not tested, needs to fix - rh_status - ;; - *) - echo $"Usage: $0 {start|stop|status|restart}" - exit 2 -esac - -exit $? -``` \ No newline at end of file