git.delta.rocks / unique-network / refs/commits / 017a48dc2d8e

difftreelog

Fix node roles, add key file

Greg Zaitsev2020-07-21parent: #9b6878d.patch.diff
in: master

2 files changed

modifieddocker-compose-testnet.ymldiffbeforeafterboth
40 - RPCPORT=993640 - RPCPORT=9936
41 - BOOTNODE=False41 - BOOTNODE=False
42 - BOOTPORT=3033542 - BOOTPORT=30335
43 - BOOTID=12D3KooWRYNrSRQvJ73esUhpyETQNJWGfC2LQ9dW3HJtzHJM28Hc43 - BOOTID=12D3KooWRLrjXxByPkSCzcsRyf6652brnJT9s4AQHR3uujJ35mxz
44 - VALIDATOR=True44 - VALIDATOR=True
4545
46 node_bohr:46 node_bohr:
62 - RPCPORT=993462 - RPCPORT=9934
63 - BOOTNODE=False63 - BOOTNODE=False
64 - BOOTPORT=3033564 - BOOTPORT=30335
65 - BOOTID=12D3KooWRYNrSRQvJ73esUhpyETQNJWGfC2LQ9dW3HJtzHJM28Hc65 - BOOTID=12D3KooWRLrjXxByPkSCzcsRyf6652brnJT9s4AQHR3uujJ35mxz
66 - VALIDATOR=False66 - VALIDATOR=False
67 67
68networks: 68networks:
modifiedrun-testnet.shdiffbeforeafterboth
--- a/run-testnet.sh
+++ b/run-testnet.sh
@@ -8,18 +8,21 @@
 echo RPC Port        : $RPCPORT
 
 echo Boot = $BOOTNODE
+echo Validator = $VALIDATOR
 
 if [ "$BOOTNODE" = True ]; 
 then
 echo This is a Bootnode;
 BOOTNODES="";
+NODEKEY="--node-key-file einstein_key_file";
 else
 echo Bootnode Port   : $BOOTPORT;
 echo Bootnode PeerID : $BOOTID;
 BOOTNODES="--bootnodes /dns4/node_einstein/tcp/$BOOTPORT/p2p/$BOOTID";
+NODEKEY="";
 fi
 
-if [ "VALIDATOR" = True ];
+if [ "$VALIDATOR" = True ];
 then
 echo This is a Validator node;
 /usr/local/bin/nft \
@@ -34,7 +37,8 @@
   --ws-external \
   --rpc-external \
   -lruntime \
-  $BOOTNODES;
+  $BOOTNODES \
+  $NODEKEY;
 else
 echo This is a Gateway node;
 /usr/local/bin/nft \
@@ -43,11 +47,8 @@
   --port $P2PPORT \
   --ws-port $WSPORT \
   --rpc-port $RPCPORT \
-  --validator \
-  --rpc-methods=Unsafe \
   --name $NODE \
   --ws-external \
-  --rpc-external \
   --rpc-cors all \
   -lruntime \
   $BOOTNODES;