Skip to content

Commit

Permalink
chore
Browse files Browse the repository at this point in the history
  • Loading branch information
tkxkd0159 committed Jun 12, 2024
1 parent 09def66 commit cfbba38
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions init_node.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ RPC_PORT=26657
P2P_PORT=26656
PROF_PORT=6060
GRPC_PORT=9090
GRPC_WEB_PORT=9091

# Set genesis file and config(port, peer, ...)
CHAIN_0_DIR="${CHAIN_DIR_PREFIX}0"
Expand Down Expand Up @@ -127,7 +126,6 @@ for ((i = 0; i < N; i++))
sed -i 's#'"${MEMO}"'#'"${MEMO_SPLIT[1]}"':'"${P2P_PORT}"'#g' ${CHAIN_0_DIR}/config/config.toml # change port of persistent_peers

sed -i 's/pruning = "default"/pruning = "nothing"/g' ${CHAIN_DIR}/config/app.toml
sed -i 's#"0.0.0.0:9091"#"0.0.0.0:'"${GRPC_WEB_PORT}"'"#g' ${CHAIN_DIR}/config/app.toml
sed -i 's#"0.0.0.0:9090"#"0.0.0.0:'"${GRPC_PORT}"'"#g' ${CHAIN_DIR}/config/app.toml
else
sed -i '' 's#"tcp://127.0.0.1:26657"#"tcp://0.0.0.0:'"${RPC_PORT}"'"#g' ${CHAIN_DIR}/config/config.toml
Expand All @@ -141,15 +139,13 @@ for ((i = 0; i < N; i++))
sed -i '' 's#'"${MEMO}"'#'"${MEMO_SPLIT[1]}"':'"${P2P_PORT}"'#g' ${CHAIN_0_DIR}/config/config.toml # change port of persistent_peers

sed -i '' 's/pruning = "default"/pruning = "nothing"/g' ${CHAIN_DIR}/config/app.toml
sed -i '' 's#"0.0.0.0:9091"#"0.0.0.0:'"${GRPC_WEB_PORT}"'"#g' ${CHAIN_DIR}/config/app.toml
sed -i '' 's#"0.0.0.0:9090"#"0.0.0.0:'"${GRPC_PORT}"'"#g' ${CHAIN_DIR}/config/app.toml
fi

echo "${BINARY} instance: home ${CHAIN_DIR} | chain-id ${CHAIN_ID} | p2p=:${P2P_PORT} | rpc=:${RPC_PORT} | profiling=:${PROF_PORT} | grpc=:${GRPC_PORT} | grpc-web=:${GRPC_WEB_PORT}"
echo "${BINARY} instance: home ${CHAIN_DIR} | chain-id ${CHAIN_ID} | p2p=:${P2P_PORT} | rpc=:${RPC_PORT} | profiling=:${PROF_PORT} | grpc=:${GRPC_PORT}"
RPC_PORT=`expr ${RPC_PORT} + 2`
P2P_PORT=`expr ${P2P_PORT} + 2`
PROF_PORT=`expr ${PROF_PORT} + 1`
GRPC_PORT=`expr ${GRPC_PORT} + 2`
GRPC_WEB_PORT=`expr ${GRPC_WEB_PORT} + 2`
done

0 comments on commit cfbba38

Please sign in to comment.