diff options
author | Matt Corallo <matt@bluematt.me> | 2011-10-25 16:48:36 -0400 |
---|---|---|
committer | Matt Corallo <matt@bluematt.me> | 2011-11-08 11:57:05 -0500 |
commit | 38f33ce4a318c8dbff648154ea4978d3ccaf8495 (patch) | |
tree | 2e1d1602ec3520ec1437f0a27c7d60f6c656ccfc /contrib/debian/bin/bitcoind | |
parent | 2b814d6eb08458c54273af8263d1f7a11f64edf5 (diff) |
Add debian build folder
Diffstat (limited to 'contrib/debian/bin/bitcoind')
-rwxr-xr-x | contrib/debian/bin/bitcoind | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/contrib/debian/bin/bitcoind b/contrib/debian/bin/bitcoind new file mode 100755 index 0000000000..0904f76f7b --- /dev/null +++ b/contrib/debian/bin/bitcoind @@ -0,0 +1,18 @@ +#!/bin/sh + +set -e + +umask 077 + +basedir=~/.bitcoin +dbfile="$basedir/DB_CONFIG" +cfgfile="$basedir/bitcoin.conf" + +[ -e "$basedir" ] || mkdir "$basedir" + +[ -e "$cfgfile" ] || perl -le 'print"rpcpassword=",map{(a..z,A..Z,0..9)[rand 62]}0..9' > "$cfgfile" + +# Bitcoin does not clean up DB log files by default +[ -e "$dbfile" ] || echo 'set_flags DB_LOG_AUTOREMOVE' > "$dbfile" + +exec /usr/lib/bitcoin/bitcoind "$@" |