forked from LayerTwo-Labs/bitcoin-patched
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
111a612
commit 668fd4f
Showing
1 changed file
with
69 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
Instructions on setting up the signet. This is using Fish shell, but should be | ||
easy enough to get the gist if using an inferior shell like Bash or Zsh. | ||
|
||
1. Create the appropriate configuration file for our network: | ||
|
||
```conf | ||
signet=1 | ||
# 1 minute block times. Note that /everyone/ who connects to this signet | ||
# must have this exact configuration value. | ||
signetblocktime=60 | ||
``` | ||
1. Generate the private key used to sign blocks + corresponding | ||
`signetchallenge` value. | ||
```fish | ||
$ mkdir l2l-signet | ||
$ ./build/src/bitcoind -daemon -regtest -datadir=$PWD/l2l-signet | ||
$ ./build/src/bitcoin-cli -regtest -datadir=$PWD/l2l-signet \ | ||
createwallet l2l-signet | ||
$ set signet_challenge (./build/src/bitcoin-cli -regtest -datadir=$PWD/l2l-signet \ | ||
getaddressinfo $address | jq -r .scriptPubKey) | ||
$ echo signetchallenge=$signet_challenge >> l2l-signet/bitcoin.conf | ||
# Need the wallet descriptors to be able to import the wallet into | ||
$ set descriptors (./build/src/bitcoin-cli -regtest -datadir=$PWD/l2l-signet \ | ||
listdescriptors true | jq -r .descriptors) | ||
# We're finished with the regtest wallet! | ||
$ ./build/src/bitcoin-cli -regtest -datadir=$PWD/l2l-signet stop | ||
``` | ||
1. Create the signet wallet | ||
```fish | ||
$ ./build/src/bitcoind -daemon -signet -datadir=$PWD/l2l-signet | ||
$ ./build/src/bitcoin-cli -signet -datadir=$PWD/l2l-signet \ | ||
createwallet l2l-signet | ||
$ ./build/src/bitcoin-cli signet -datadir=$PWD/l2l-signet \ | ||
importdescriptors "$descriptors" | ||
``` | ||
1. Start mining on our network: | ||
```fish | ||
$ set address (./build/src/bitcoin-cli -signet -datadir=$PWD/l2l-signet getnewaddress) | ||
$ ./contrib/signet/miner \ | ||
--cli "bitcoin-cli -signet -datadir=$PWD/l2l-signet" \ | ||
generate --address $address \ | ||
--grind-cmd "$PWD/build/src/bitcoin-util grind" \ | ||
--min-nbits --ongoing --block-interval 60 | ||
``` | ||
``` | ||
|
||
``` | ||
``` | ||
|
||
``` |