Skip to content

Commit

Permalink
oopsie daisy
Browse files Browse the repository at this point in the history
  • Loading branch information
usmanmani1122 committed Jan 3, 2025
1 parent ea008d0 commit a8106ca
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions a3p-integration/proposals/z:acceptance/pre_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@ FOLLOWER_P2P_PORT="36656"
FOLLOWER_PPROF_PORT="7060"
FOLLOWER_RPC_PORT="36657"
LOADGEN_REPOSITORY_NAME="testnet-load-generator"
MESSAGE_FILE_PATH="/tmp/message-file-path.tmp"
MESSAGE_FILE_NAME='message-file-path.tmp'
ORGANIZATION_NAME="agoric"
TIMESTAMP="$(date '+%s')"
VALIDATOR_NODE_ID=""
VALIDATOR_P2P_PORT="26656"
VALIDATOR_RPC_PORT="26657"

CONTAINER_IMAGE_NAME="ghcr.io/$ORGANIZATION_NAME/agoric-3-proposals"
CONTAINER_MESSAGE_FILE_PATH="/root/$MESSAGE_FILE_NAME"
HOST_MESSAGE_FILE_PATH="$HOME/$MESSAGE_FILE_NAME"
LOADGEN_REPOSITORY_LINK="https://github.com/$ORGANIZATION_NAME/$LOADGEN_REPOSITORY_NAME.git"
NETWORK_CONFIG_FILE_PATH="/tmp/network-config-$TIMESTAMP"
OUTPUT_DIRECTORY="/tmp/loadgen-output"
Expand All @@ -28,6 +30,7 @@ FOLLOWER_CONTAINER_NAME="$PROPOSAL_NAME-follower"
FOLLOWER_LOGS_FILE="/tmp/loadgen-follower-logs"

create_volume_assets() {
touch "$HOST_MESSAGE_FILE_PATH"
mkdir --parents "$OUTPUT_DIRECTORY"
}

Expand Down Expand Up @@ -129,16 +132,16 @@ start_follower() {
"$FOLLOWER_CONTAINER_NAME" \
--env "API_PORT=$FOLLOWER_API_PORT" \
--env "GRPC_PORT=$FOLLOWER_GRPC_PORT" \
--env "MESSAGE_FILE_PATH=$MESSAGE_FILE_PATH" \
--env "MESSAGE_FILE_PATH=$CONTAINER_MESSAGE_FILE_PATH" \
--env "OUTPUT_DIR=$OUTPUT_DIRECTORY" \
--env "P2P_PORT=$FOLLOWER_P2P_PORT" \
--env "PPROF_PORT=$FOLLOWER_PPROF_PORT" \
--env "RPC_PORT=$FOLLOWER_RPC_PORT" \
--env "TRUSTED_BLOCK_HASH=$TRUSTED_BLOCK_HASH" \
--env "TRUSTED_BLOCK_HEIGHT=$TRUSTED_BLOCK_HEIGHT" \
--volume "$MESSAGE_FILE_PATH:$MESSAGE_FILE_PATH" \
--volume "$OUTPUT_DIRECTORY:$OUTPUT_DIRECTORY" \
--volume "$NETWORK_CONFIG_FILE_PATH:$NETWORK_CONFIG_FILE_PATH/network-config" > "$FOLLOWER_LOGS_FILE" &
--mount "source=$HOST_MESSAGE_FILE_PATH,target=$CONTAINER_MESSAGE_FILE_PATH,type=bind" \
--mount "source=$OUTPUT_DIRECTORY,target=$OUTPUT_DIRECTORY,type=bind" \
--mount "source=$NETWORK_CONFIG_FILE_PATH,target=$NETWORK_CONFIG_FILE_PATH/network-config,type=bind" >"$FOLLOWER_LOGS_FILE" &
}

write_network_config() {
Expand Down

0 comments on commit a8106ca

Please sign in to comment.