Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dockernet Slash Test Configuration #330

Merged
merged 3 commits into from
Nov 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions scripts/init_chain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,12 @@ set_host_genesis() {
jq "del(.app_state.interchain_accounts)" $genesis_config > json.tmp && mv json.tmp $genesis_config
interchain_accts=$(cat $SCRIPT_DIR/config/ica.json)
jq ".app_state += $interchain_accts" $genesis_config > json.tmp && mv json.tmp $genesis_config

# Slightly harshen slashing parameters (if 5 blocks are missed, the validator will be slashed)
# This makes it easier to test updating weights after a host zone validator is slashed
sed -i -E 's|"signed_blocks_window": "100"|"signed_blocks_window": "10"|g' $genesis_config
sed -i -E 's|"downtime_jail_duration": "600s"|"downtime_jail_duration": "10s"|g' $genesis_config
sed -i -E 's|"slash_fraction_downtime": "0.010000000000000000"|"slash_fraction_downtime": "0.100000000000000000"|g' $genesis_config
}

MAIN_ID=1 # Node responsible for genesis and persistent_peers
Expand Down
2 changes: 1 addition & 1 deletion scripts/start_network.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,4 @@ for chain_id in ${HOST_CHAINS[@]}; do
docker-compose logs -f relayer-${chain_name} | sed -r -u "s/\x1B\[([0-9]{1,3}(;[0-9]{1,2})?)?[mGK]//g" >> ${LOGS}/relayer-${chain_name}.log 2>&1 &
done

$SCRIPT_DIR/create_logs.sh ${HOST_CHAINS[@]} &
$SCRIPT_DIR/create_logs.sh ${HOST_CHAINS[@]} &