mirror of
https://github.com/openoms/bitcoin-tutorials.git
synced 2025-12-20 05:14:19 +01:00
electrs: use rm -f and fail if chnmod 600 fails
This commit is contained in:
@@ -21,14 +21,14 @@ To download and run:
|
||||
|
||||
### Setting up BTCPayServer
|
||||
|
||||
* Go to your domain.
|
||||
* Create a Store.
|
||||
* Go to your domain
|
||||
* Register the first (administrator) account
|
||||
* Create a Store
|
||||
* In Store settings set up the derivation scheme (add an xpub)
|
||||
* Set up LN with the connection string:
|
||||
`type=lnd-rest;server=https://127.0.0.1:8080/;macaroonfilepath=/home/admin/.lnd/data/chain/bitcoin/mainnet/admin.macaroon;allowinsecure=true`
|
||||
|
||||
* Continue with: https://docs.btcpayserver.org/btcpay-basics/gettingstarted
|
||||
|
||||
* Find more detailed info on https://docs.btcpayserver.org/btcpay-basics/gettingstarted
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -57,12 +57,11 @@ echo ""
|
||||
# generate setting file: https://github.com/romanz/electrs/issues/170#issuecomment-530080134
|
||||
# https://github.com/romanz/electrs/blob/master/doc/usage.md#configuration-files-and-environment-variables
|
||||
|
||||
sudo rm /home/electrs/.electrs/config.toml 2>/dev/null
|
||||
sudo rm -f /home/electrs/.electrs/config.toml
|
||||
sudo -u electrs mkdir /home/electrs/.electrs 2>/dev/null
|
||||
|
||||
|
||||
touch /home/admin/config.toml
|
||||
chmod 600 /home/admin/config.toml
|
||||
chmod 600 /home/admin/config.toml || exit 1
|
||||
cat > /home/admin/config.toml <<EOF
|
||||
verbose = 4
|
||||
timestamp = true
|
||||
|
||||
Reference in New Issue
Block a user