diff --git a/init.sh b/init.sh index 6cf61d3..aa7483f 100755 --- a/init.sh +++ b/init.sh @@ -80,6 +80,10 @@ artela-rollkitd add-genesis-account $KEY4 100000000000000000000000000aart --keyr echo gentx $KEY 1000000000000000000000aart --keyring-backend $KEYRING --chain-id $CHAINID artela-rollkitd gentx $KEY 1000000000000000000000aart --keyring-backend $KEYRING --chain-id $CHAINID --fees 4000000000000000aart +ADDRESS=$(jq -r '.address' ~/.artroll/config/priv_validator_key.json) +PUB_KEY=$(jq -r '.pub_key' ~/.artroll/config/priv_validator_key.json) +jq --argjson pubKey "$PUB_KEY" '.consensus["validators"]=[{"address": "'$ADDRESS'", "pub_key": $pubKey, "power": "1000000000000000", "name": "Rollkit Sequencer"}]' ~/.artroll/config/genesis.json > temp.json && mv temp.json ~/.artroll/config/genesis.json + # Collect genesis tx artela-rollkitd collect-gentxs @@ -145,4 +149,4 @@ if [[ $1 == "pending" ]]; then sed -i 's/timeout_commit = "5s"/timeout_commit = "150s"/g' $HOME/.artroll/config/config.toml sed -i 's/timeout_broadcast_tx_commit = "10s"/timeout_broadcast_tx_commit = "150s"/g' $HOME/.artroll/config/config.toml fi -fi \ No newline at end of file +fi