Skip to content

Commit

Permalink
Merge pull request #93 from cheqd/fix_test_net
Browse files Browse the repository at this point in the history
Add `cheq` coins to test_net docker instead of `stake` and `token` coins
  • Loading branch information
askolesov authored Aug 6, 2021
2 parents dad86f8 + 9099c4c commit 107e7c0
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions ci/docker_testnet/gen_node_configs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,24 +38,26 @@ echo "##### [Validator operators] Init genesis"

cheqd-noded init dummy_node --chain-id $CHAIN_ID --home $CLIENT_HOME

sed -i 's/"stake"/"cheq"/' ${CLIENT_HOME}/config/genesis.json

echo "##### [Validator operators] Add them to the genesis"

cheqd-noded add-genesis-account alice 10000000cheq,100000000stake --home $CLIENT_HOME
cheqd-noded add-genesis-account bob 10000000cheq,100000000stake --home $CLIENT_HOME
cheqd-noded add-genesis-account alice 20000000cheq --home $CLIENT_HOME
cheqd-noded add-genesis-account bob 20000000cheq --home $CLIENT_HOME



echo "##### [Test pool] Add test account to the genesis"

ACCOUNT_ID="cosmos1fknpjldck6n3v2wu86arpz8xjnfc60f99ylcjd"
echo $(cat ${CLIENT_HOME}/config/genesis.json | jq '.app_state.bank.balances += [{"address": "'${ACCOUNT_ID}'", "coins": [{"denom": "stake", "amount": "100000000"},{"denom": "cheq", "amount": "1000"}] }]') > ${CLIENT_HOME}/config/genesis.json
echo $(cat ${CLIENT_HOME}/config/genesis.json | jq '.app_state.bank.balances += [{"address": "'${ACCOUNT_ID}'", "coins": [{"denom": "cheq", "amount": "100001000"}] }]') > ${CLIENT_HOME}/config/genesis.json
echo $(cat ${CLIENT_HOME}/config/genesis.json | jq '.app_state.auth.accounts += [{"@type": "/cosmos.auth.v1beta1.BaseAccount","address": "'${ACCOUNT_ID}'", "pub_key": null,"account_number": "0","sequence": "0"}]') > ${CLIENT_HOME}/config/genesis.json


echo "##### [Validator operators] Generate stake transactions"

cheqd-noded gentx alice 1000000stake --chain-id $CHAIN_ID --node-id $NODE_0_ID --pubkey $NODE_0_VAL_PUBKEY --home $CLIENT_HOME
cheqd-noded gentx bob 1000000stake --chain-id $CHAIN_ID --node-id $NODE_1_ID --pubkey $NODE_1_VAL_PUBKEY --home $CLIENT_HOME
cheqd-noded gentx alice 1000000cheq --chain-id $CHAIN_ID --node-id $NODE_0_ID --pubkey $NODE_0_VAL_PUBKEY --home $CLIENT_HOME
cheqd-noded gentx bob 1000000cheq --chain-id $CHAIN_ID --node-id $NODE_1_ID --pubkey $NODE_1_VAL_PUBKEY --home $CLIENT_HOME


echo "##### [Validator operators] Collect them"
Expand Down

0 comments on commit 107e7c0

Please sign in to comment.