diff options
| author | J Ross Nicoll <[email protected]> | 2015-08-15 11:36:26 +0100 |
|---|---|---|
| committer | J Ross Nicoll <[email protected]> | 2015-10-31 14:49:41 +0000 |
| commit | a21fa1ad61e9ceb7c2dd9e855c49edc9b70aade5 (patch) | |
| tree | dd3ebe4ea1e6d3d4ba40db96768fa36fff95a7a6 /contrib/init/dogecoind.init | |
| parent | Replace Bitcoin icons with Dogecoin (diff) | |
| download | discoin-a21fa1ad61e9ceb7c2dd9e855c49edc9b70aade5.tar.xz discoin-a21fa1ad61e9ceb7c2dd9e855c49edc9b70aade5.zip | |
s/bitcoin/dogecoin/ in init scripts
Diffstat (limited to 'contrib/init/dogecoind.init')
| -rw-r--r-- | contrib/init/dogecoind.init | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/contrib/init/dogecoind.init b/contrib/init/dogecoind.init new file mode 100644 index 000000000..c00d18f7e --- /dev/null +++ b/contrib/init/dogecoind.init @@ -0,0 +1,67 @@ +#!/bin/bash +# +# dogecoind The dogecoin core server. +# +# +# chkconfig: 345 80 20 +# description: dogecoind +# processname: dogecoind +# + +# Source function library. +. /etc/init.d/functions + +# you can override defaults in /etc/sysconfig/dogecoind, see below +if [ -f /etc/sysconfig/dogecoind ]; then + . /etc/sysconfig/dogecoind +fi + +RETVAL=0 + +prog=dogecoind +# you can override the lockfile via DOGECOIND_LOCKFILE in /etc/sysconfig/dogecoind +lockfile=${DOGECOIND_LOCKFILE-/var/lock/subsys/dogecoind} + +# dogecoind defaults to /usr/bin/dogecoind, override with DOGECOIND_BIN +dogecoind=${DOGECOIND_BIN-/usr/bin/dogecoind} + +# dogecoind opts default to -disablewallet, override with DOGECOIND_OPTS +dogecoind_opts=${DOGECOIND_OPTS--disablewallet} + +start() { + echo -n $"Starting $prog: " + daemon $DAEMONOPTS $dogecoind $dogecoind_opts + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && touch $lockfile + return $RETVAL +} + +stop() { + echo -n $"Stopping $prog: " + killproc $prog + RETVAL=$? + echo + [ $RETVAL -eq 0 ] && rm -f $lockfile + return $RETVAL +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + status) + status $prog + ;; + restart) + stop + start + ;; + *) + echo "Usage: service $prog {start|stop|status|restart}" + exit 1 + ;; +esac |