Harvest DragonX packaging + legal artifacts from compliant-rebrand
Legal: correct GPLv3 LICENSE (fixes garbled 'GENERAL GENERAL'), AUTHORS DragonX attribution, COPYING. Packaging: man pages REGENERATED from the 1.0.3 binaries via help2man (dragonxd/dragonx-cli/dragonx-tx.1 -> v1.0.3, correct dates), wired into doc/man/Makefile.am (dist_man1_MANS), orphaned hush*.1 removed. Init/openrc/systemd scripts, Debian packaging (control/changelog/copyright rebranded hush->dragonx + install stubs), example confs taken from origin/compliant-rebrand (c05134e77). REMAINING follow-ups: (1) debian/changelog still tops at 1.0.0 - add a 1.0.3 entry; (2) dragonx-cli --help hardcodes rpcport default 18030 (hush) - fix the HelpMessage string in source then regen. Staged on 176 for review; not pushed.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
59
contrib/init/dragonxd.conf
Normal file
59
contrib/init/dragonxd.conf
Normal file
@@ -0,0 +1,59 @@
|
||||
description "Hush Daemon"
|
||||
|
||||
start on runlevel [2345]
|
||||
stop on starting rc RUNLEVEL=[016]
|
||||
|
||||
env HUSHD_BIN="/usr/bin/dragonxd"
|
||||
env HUSHD_USER="hush"
|
||||
env HUSHD_GROUP="hush"
|
||||
env HUSHD_PIDDIR="/var/run/dragonxd"
|
||||
# upstart can't handle variables constructed with other variables
|
||||
env HUSHD_PIDFILE="/var/run/dragonxd/dragonxd.pid"
|
||||
env HUSHD_CONFIGFILE="/etc/hush/hush.conf"
|
||||
env HUSHD_DATADIR="/var/lib/dragonxd"
|
||||
|
||||
expect fork
|
||||
|
||||
respawn
|
||||
respawn limit 5 120
|
||||
kill timeout 60
|
||||
|
||||
pre-start script
|
||||
# this will catch non-existent config files
|
||||
# dragonxd will check and exit with this very warning, but it can do so
|
||||
# long after forking, leaving upstart to think everything started fine.
|
||||
# since this is a commonly encountered case on install, just check and
|
||||
# warn here.
|
||||
if ! grep -qs '^rpcpassword=' "$HUSHD_CONFIGFILE" ; then
|
||||
echo "ERROR: You must set a secure rpcpassword to run dragonxd."
|
||||
echo "The setting must appear in $HUSHD_CONFIGFILE"
|
||||
echo
|
||||
echo "This password is security critical to securing wallets "
|
||||
echo "and must not be the same as the rpcuser setting."
|
||||
echo "You can generate a suitable random password using the following"
|
||||
echo "command from the shell:"
|
||||
echo
|
||||
echo "bash -c 'tr -dc a-zA-Z0-9 < /dev/urandom | head -c32 && echo'"
|
||||
echo
|
||||
exit 1
|
||||
fi
|
||||
|
||||
mkdir -p "$HUSHD_PIDDIR"
|
||||
chmod 0755 "$HUSHD_PIDDIR"
|
||||
chown $HUSHD_USER:$HUSHD_GROUP "$HUSHD_PIDDIR"
|
||||
chown $HUSHD_USER:$HUSHD_GROUP "$HUSHD_CONFIGFILE"
|
||||
chmod 0660 "$HUSHD_CONFIGFILE"
|
||||
end script
|
||||
|
||||
exec start-stop-daemon \
|
||||
--start \
|
||||
--pidfile "$HUSHD_PIDFILE" \
|
||||
--chuid $HUSHD_USER:$HUSHD_GROUP \
|
||||
--exec "$HUSHD_BIN" \
|
||||
-- \
|
||||
-pid="$HUSHD_PIDFILE" \
|
||||
-conf="$HUSHD_CONFIGFILE" \
|
||||
-datadir="$HUSHD_DATADIR" \
|
||||
-disablewallet \
|
||||
-daemon
|
||||
|
||||
Reference in New Issue
Block a user