Added regtest support

This commit is contained in:
SKP
2019-07-19 11:28:52 +02:00
committed by kexkey
parent 48415464c2
commit 0cc325e60b
6 changed files with 26 additions and 6 deletions

View File

@@ -34,6 +34,9 @@ module.exports = {
},{
name: "Mainnet",
value: "mainnet"
},{
name: "RegTest",
value: "regtest"
}]
},
{

View File

@@ -178,7 +178,8 @@
"type": "string",
"enum": [
"testnet",
"mainnet"
"mainnet",
"regtest"
],
"title": "The net cyphernode is running on",
"default": "testnet",

View File

@@ -1,6 +1,9 @@
<% if (net === 'testnet') { %>
# testnet
testnet=1
<% } else if( net === 'regtest' ) { %>
# regtest
regtest=1
<% } %>
<% if (bitcoin_prune && bitcoin_mode === 'internal') { %>
@@ -32,6 +35,13 @@ test.wallet=xpubwatching01.dat
test.wallet=spending01.dat
test.wallet=ln01.dat
test.rpcbind=0.0.0.0
<% } else if ( net === 'regtest' ) { %>
regtest.wallet=watching01.dat
regtest.wallet=xpubwatching01.dat
regtest.wallet=spending01.dat
regtest.wallet=ln01.dat
regtest.rpcbind=0.0.0.0
regtest.rpcport=18443
<% } else { %>
main.wallet=watching01.dat
main.wallet=xpubwatching01.dat

View File

@@ -52,12 +52,12 @@ services:
# Bitcoin Mini Proxy
environment:
- "TRACING=1"
- "WATCHER_BTC_NODE_RPC_URL=<%= (bitcoin_mode === 'internal')?'bitcoin':bitcoin_node_ip %>:<%= (net === 'mainnet')?'8332':'18332' %>/wallet"
- "WATCHER_BTC_NODE_RPC_URL=<%= (bitcoin_mode === 'internal')?'bitcoin':bitcoin_node_ip %>:<%= (net === 'regtest')?'18443':((net === 'testnet')?'18332':'8332') %>/wallet"
- "WATCHER_BTC_NODE_DEFAULT_WALLET=watching01.dat"
- "WATCHER_BTC_NODE_XPUB_WALLET=xpubwatching01.dat"
- "WATCHER_BTC_NODE_RPC_USER=<%= bitcoin_rpcuser %>:<%= bitcoin_rpcpassword %>"
- "WATCHER_BTC_NODE_RPC_CFG=/tmp/watcher_btcnode_curlcfg.properties"
- "SPENDER_BTC_NODE_RPC_URL=<%= (bitcoin_mode === 'internal')?'bitcoin':bitcoin_node_ip %>:<%= (net === 'mainnet')?'8332':'18332' %>/wallet"
- "SPENDER_BTC_NODE_RPC_URL=<%= (bitcoin_mode === 'internal')?'bitcoin':bitcoin_node_ip %>:<%= (net === 'regtest')?'18443':((net === 'testnet')?'18332':'8332') %>/wallet"
- "SPENDER_BTC_NODE_DEFAULT_WALLET=spending01.dat"
- "SPENDER_BTC_NODE_RPC_USER=<%= bitcoin_rpcuser %>:<%= bitcoin_rpcpassword %>"
- "SPENDER_BTC_NODE_RPC_CFG=/tmp/spender_btcnode_curlcfg.properties"
@@ -164,7 +164,7 @@ services:
image: cyphernode/bitcoin:<%= bitcoin_version %>
<% if( bitcoin_expose ) { %>
ports:
- "<%= (net === 'mainnet')?'8332:8332':'18332:18332' %>"
- "<%= (net === 'regtest')?'18443:18443':((net === 'testnet')?'18332:18332':'8332:8332') %>"
<% } %>
# deploy:
# placement:
@@ -200,4 +200,4 @@ networks:
cyphernodenet:
external: true
cyphernodeappsnet:
external: true
external: true

View File

@@ -1,6 +1,9 @@
<% if (net === 'testnet') { %>
# testnet
testnet=1
<% } else if( net === 'regtest' ) { %>
# regtest
regtest=1
<% } %>
rpcconnect=<%= (bitcoin_mode === 'internal')?'bitcoin':bitcoin_node_ip %>

View File

@@ -1,4 +1,7 @@
<% if (net === 'testnet') { %>
<% if (net === 'regtest') { %>
# regtest
network=regtest
<% } else if (net === 'testnet') { %>
# testnet
network=testnet
<% } else if (net === 'mainnet') { %>