Merge pull request #2466 from yancyribbens/enable-docker-mainnet

enable btcd and btcctl mainnet to be invoked from docker
This commit is contained in:
Olaoluwa Osuntokun 2019-01-15 16:59:42 -08:00 committed by GitHub
commit 7df0e6fafe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 9 deletions

@ -43,10 +43,17 @@ RPCUSER=$(set_default "$RPCUSER" "devuser")
RPCPASS=$(set_default "$RPCPASS" "devpass")
NETWORK=$(set_default "$NETWORK" "simnet")
exec btcctl \
"--$NETWORK" \
--rpccert="/rpc/rpc.cert" \
--rpcuser="$RPCUSER" \
--rpcpass="$RPCPASS" \
--rpcserver="rpcserver" \
"$@"
PARAMS=""
if [ "$NETWORK" != "mainnet" ]; then
PARAMS=$(echo --$NETWORK)
fi
PARAMS=$(echo $PARAMS \
"--rpccert=/rpc/rpc.cert" \
"--rpcuser=$RPCUSER" \
"--rpcpass=$RPCPASS" \
"--rpcserver=rpcserver" \
)
PARAMS="$PARAMS $@"
exec btcctl $PARAMS

@ -44,8 +44,12 @@ RPCPASS=$(set_default "$RPCPASS" "devpass")
DEBUG=$(set_default "$DEBUG" "info")
NETWORK=$(set_default "$NETWORK" "simnet")
PARAMS=$(echo \
"--$NETWORK" \
PARAMS=""
if [ "$NETWORK" != "mainnet" ]; then
PARAMS=$(echo --$NETWORK)
fi
PARAMS=$(echo $PARAMS \
"--debuglevel=$DEBUG" \
"--rpcuser=$RPCUSER" \
"--rpcpass=$RPCPASS" \