Skip to content

Commit fa2f991

Browse files
torkelrogstadfanquake
authored andcommitted
doc: add note on precedence of options in bitcoin.conf
1 parent fe00192 commit fa2f991

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

doc/bitcoin-conf.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,21 @@ Network specific options can be:
3030
- placed into sections with headers `[main]` (not `[mainnet]`), `[test]` (not `[testnet]`) or `[regtest]`;
3131
- prefixed with a chain name; e.g., `regtest.maxmempool=100`.
3232

33+
Network specific options take precedence over non-network specific options.
34+
If multiple values for the same option are found with the same precedence, the
35+
first one is generally chosen.
36+
37+
This means that given the following configuration, `regtest.rpcport` is set to `3000`:
38+
39+
```
40+
regtest=1
41+
rpcport=2000
42+
regtest.rpcport=3000
43+
44+
[regtest]
45+
rpcport=4000
46+
```
47+
3348
## Configuration File Path
3449

3550
The configuration file is not automatically created; you can create it using your favorite text editor. By default, the configuration file name is `bitcoin.conf` and it is located in the Bitcoin data directory, but both the Bitcoin data directory and the configuration file path may be changed using the `-datadir` and `-conf` command-line options.

0 commit comments

Comments
 (0)