generated from dymensionxyz/rollapp
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
76c3855
commit 15c578d
Showing
2 changed files
with
35 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,26 @@ | ||
#!/bin/bash | ||
|
||
KEYRING_PATH="$HOME/.rollapp/sequencer_keys" | ||
KEY_NAME_SEQUENCER="sequencer" | ||
MAX_SEQUENCERS=5 | ||
|
||
#Register rollapp | ||
dymd tx rollapp create-rollapp "$ROLLAPP_CHAIN_ID" "$MAX_SEQUENCERS" '{"Addresses":[]}' \ | ||
--from "$KEY_NAME_SEQUENCER" \ | ||
--keyring-backend test \ | ||
--keyring-dir "$KEYRING_PATH" \ | ||
--broadcast-mode block \ | ||
--fees 20000000000000adym \ | ||
-y | ||
MAX_SEQUENCERS=1 | ||
|
||
# this account must be whitelisted on the hub for permissioned deployment setup | ||
DEPLOYER=${HUB_PERMISSIONED_KEY-"$HUB_KEY_WITH_FUNDS"} | ||
SEQUENCER_ADDR=$(dymd keys show sequencer --address --keyring-backend test --keyring-dir "$ROLLAPP_HOME_DIR"/sequencer_keys) | ||
|
||
if [ "$HUB_RPC_URL" = "" ]; then | ||
echo "HUB_RPC_URL is not set, using 'http://localhost:36657'" | ||
HUB_RPC_URL="http://localhost:36657" | ||
fi | ||
|
||
if [ "$HUB_CHAIN_ID" = "" ]; then | ||
echo "HUB_CHAIN_ID is not set, using 'dymension_100-1'" | ||
HUB_CHAIN_ID="dymension_100-1" | ||
fi | ||
|
||
set -x | ||
dymd tx rollapp create-rollapp "$ROLLAPP_CHAIN_ID" "$MAX_SEQUENCERS" "{\"Addresses\":[\"${SEQUENCER_ADDR}\"]}" \ | ||
"$ROLLAPP_HOME_DIR"/init/denommetadata.json \ | ||
--genesis-accounts-path "$ROLLAPP_HOME_DIR"/init/genesis_accounts.json \ | ||
--from "$DEPLOYER" \ | ||
--keyring-backend test --broadcast-mode block \ | ||
--fees 1dym | ||
set +x |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,21 @@ | ||
#!/bin/bash | ||
|
||
EXECUTABLE="rollappd" | ||
KEYRING_PATH="$HOME/.rollapp/sequencer_keys" | ||
KEYRING_PATH="$HOME/.rollapp_evm/sequencer_keys" | ||
KEY_NAME_SEQUENCER="sequencer" | ||
|
||
|
||
#Register Sequencer | ||
DESCRIPTION="{\"Moniker\":\"myrollapp-sequencer\",\"Identity\":\"\",\"Website\":\"\",\"SecurityContact\":\"\",\"Details\":\"\"}"; | ||
SEQ_PUB_KEY="$($EXECUTABLE dymint show-sequencer)" | ||
DESCRIPTION="{\"Moniker\":\"${ROLLAPP_CHAIN_ID}-sequencer\",\"Identity\":\"\",\"Website\":\"\",\"SecurityContact\":\"\",\"Details\":\"\"}" | ||
SEQ_PUB_KEY="$("$EXECUTABLE" dymint show-sequencer)" | ||
BOND_AMOUNT="$(dymd q sequencer params -o json --node "$HUB_RPC_URL" | jq -r '.params.min_bond.amount')$(dymd q sequencer params -o json --node "$HUB_RPC_URL" | jq -r '.params.min_bond.denom')" | ||
|
||
dymd tx sequencer create-sequencer "$SEQ_PUB_KEY" "$ROLLAPP_CHAIN_ID" "$DESCRIPTION" 20000000000000adym\ | ||
set -x | ||
dymd tx sequencer create-sequencer "$SEQ_PUB_KEY" "$ROLLAPP_CHAIN_ID" "$DESCRIPTION" "$BOND_AMOUNT" \ | ||
--from "$KEY_NAME_SEQUENCER" \ | ||
--keyring-dir "$KEYRING_PATH" \ | ||
--keyring-backend test \ | ||
--broadcast-mode block \ | ||
--fees 20000000000000adym \ | ||
-y | ||
--fees 1dym \ | ||
-y | ||
|
||
set +x | ||
|