btcpayserver/BTCPayServer.Tests/docker-bitcoin-generate.sh
Dennis Reimann fe45152529
Add bitcoin generate shell script
The shell equivalent to the existing powershell script.
2020-04-07 18:13:47 +02:00

6 lines
359 B
Bash
Executable File

#!/bin/bash
bitcoind_container_id="$(docker ps -q --filter label=com.docker.compose.project=btcpayservertests --filter label=com.docker.compose.service=bitcoind)"
address=$(docker exec -ti $bitcoind_container_id bitcoin-cli -datadir="/data" getnewaddress)
docker exec -ti $bitcoind_container_id bitcoin-cli -datadir="/data" generatetoaddress "$@" "$address"