Commit 1335338a authored by vicotor's avatar vicotor

add custom chainid

parent 2e1363b3
......@@ -2,6 +2,7 @@ nodes = 1
index = 4
Join = false
webrtc = false
chainid = 1024
# generate keys and peers.json file
......@@ -11,8 +12,12 @@ install:
conf :
@rm -rf conf
@PATH=/tmp/tmpbin:${PATH} ./scripts/build-conf.sh $(nodes) $(webrtc)
@PATH=/tmp/tmpbin:${PATH} CHAINID=${chainid} ./scripts/build-conf.sh $(nodes) $(webrtc)
@sed -i 's/300ms/1000ms/g' conf/deploy/node1/config/config.toml
@chown ${USER}:${USER} -R ./conf
backup: stop
cp -r conf/deploy conf/back$(shell date +%m%d-%H%M)
start:
./scripts/run-testnet.sh $(nodes) $(Join) $(webrtc)
......@@ -22,8 +27,9 @@ stop:
clean:
@rm -rf conf/deploy
.PHONY: up build conf start watch stop show bombard send join leave demo
.PHONY: up build conf start watch stop show bombard send join leave demo backup
......@@ -15,7 +15,7 @@ WORKDEPLOY=$DEST/deploy
rm -rf ~/.cmp*
cmpcli config keyring-backend test
cmpcli config chain-id 256256
cmpcli config chain-id $CHAINID
cmpcli config output json
cmpcli config indent true
cmpcli config trust-node true
......@@ -31,7 +31,7 @@ do
dest=$DEPLOY/node$i
mkdir -p $dest
echo "Generating and init node dir for node$i"
cmpd init node$i --chain-id 256256 --home $dest
cmpd init node$i --chain-id $CHAINID --home $dest
fi
done
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment