btcpayserver / btcpayserver-doc

BTCPay Server Official Documentation
https://docs.btcpayserver.org
379 stars 258 forks source link

Document pruning when using a full node datadir #602

Closed kornpow closed 4 years ago

kornpow commented 4 years ago

I was looking to try out btcpayserver, and so I started it up and then linked to my full node datadir as per the instructions. It doesnt document the fact that it puts your node into pruning mode. This is a pretty big inconvenience ;) I think there should be a note there documenting this.

Kukks commented 4 years ago

BTCPay doesn't do it automatically. If you're using the docker deployment, and you've set it to prune, it will configure bitcoind to prune older blocks.

britttttk commented 4 years ago

@sako0938 was there any particular doc page that you were using, which you suggest adding this to?

kornpow commented 4 years ago

I started from here: http://docs.btcpayserver.org/FAQ/FAQ-Synchronization/#im-running-a-full-node-and-have-a-synched-blockchain-can-btcpay-use-it-so-that-it-doesnt-have-to-do-a-full-sync

Clicked the "Do the normal setup according to this instruction": Which took me here: https://github.com/btcpayserver/btcpayserver-docker/blob/master/README.md

# Run btcpay-setup.sh with the right parameters export BTCPAY_HOST="btcpay.EXAMPLE.com" export NBITCOIN_NETWORK="mainnet" export BTCPAYGEN_CRYPTO1="btc" export BTCPAYGEN_ADDITIONAL_FRAGMENTS="opt-save-storage-s" export BTCPAYGEN_REVERSEPROXY="nginx" export BTCPAYGEN_LIGHTNING="clightning" export BTCPAY_ENABLE_SSH=true . ./btcpay-setup.sh -i

I would either remove or document the line: export BTCPAYGEN_ADDITIONAL_FRAGMENTS="opt-save-storage-s"

I dont think you should be encouraging pruned nodes so probably delete it. Most of the other environment variables are pretty self explanatory, but this one was not. Maybe if "opt-save-storage-s" had prune somewhere in the name it would be more obvious.

Thanks for the quick responses though.

britttttk commented 4 years ago

@sak0938 I think your suggestion is valid and we should add a note in that FAQ. Since I agree, you are probably right that most users doing this with an existing datadir are probably not wanting pruned. We should at least mention it to alert users to keep it or remove it, not just say "Do the normal setup according to this instruction."