Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a option to use blocksdir config for bitcoin blocks directory #1

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docker/my-dojo/.env
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ BITCOIND_LINUX_GID=1108

BITCOIND_DNSSEED=0
BITCOIND_DNS=0
BITCOIND_BLOCKS_DIR=/dev/null


#########################################
Expand Down
8 changes: 8 additions & 0 deletions docker/my-dojo/bitcoin/restart.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ if [ "$BITCOIND_BLOOM_FILTERS" == "on" ]; then
bitcoind_options+=(-peerbloomfilters=1)
fi

if [ "$BITCOIND_BLOCKS_DIR" != "/dev/null" ]; then
# To use this first create the directory on the host and give it the correct permissions
# sudo mkdir BITCOIND_BLOCKS_DIR
# sudo chmod u+rwx -R BITCOIND_BLOCKS_DIR
# sudo chown 1000:1000 -R BITCOIND_BLOCKS_DIR
bitcoind_options+=(-blocksdir="$BITCOIND_BLOCKS_DIR")
fi

if [ "$COMMON_BTC_NETWORK" == "testnet" ]; then
bitcoind_options+=(-testnet)
fi
Expand Down
1 change: 1 addition & 0 deletions docker/my-dojo/overrides/bitcoind.install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ services:
volumes:
- data-bitcoind:/home/bitcoin/.bitcoin
- data-tor:/var/lib/tor
- ${BITCOIND_BLOCKS_DIR}:$BITCOIND_BLOCKS_DIR
logging:
driver: "json-file"
options:
Expand Down