From 8d5ca5010442c66390913286a1b52b7daa78de52 Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Mon, 6 May 2024 13:47:01 +0530 Subject: [PATCH] Add an option to allow unprotected txs in geth --- .../compose/docker-compose-fixturenet-eth.yml | 1 + .../container-build/cerc-fixturenet-eth-geth/run-el.sh | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/stack-orchestrator/compose/docker-compose-fixturenet-eth.yml b/stack-orchestrator/compose/docker-compose-fixturenet-eth.yml index 4608a2a..3c75119 100644 --- a/stack-orchestrator/compose/docker-compose-fixturenet-eth.yml +++ b/stack-orchestrator/compose/docker-compose-fixturenet-eth.yml @@ -25,6 +25,7 @@ services: CERC_RUN_STATEDIFF: ${CERC_RUN_STATEDIFF:-detect} CERC_STATEDIFF_DB_NODE_ID: 1 CERC_SCRIPT_DEBUG: ${CERC_SCRIPT_DEBUG} + CERC_ALLOW_UNPROTECTED_TXS: ${CERC_ALLOW_UNPROTECTED_TXS:-false} env_file: - ../config/fixturenet-eth/fixturenet-eth.env image: cerc/fixturenet-eth-geth:local diff --git a/stack-orchestrator/container-build/cerc-fixturenet-eth-geth/run-el.sh b/stack-orchestrator/container-build/cerc-fixturenet-eth-geth/run-el.sh index be35c8b..7187629 100755 --- a/stack-orchestrator/container-build/cerc-fixturenet-eth-geth/run-el.sh +++ b/stack-orchestrator/container-build/cerc-fixturenet-eth-geth/run-el.sh @@ -50,6 +50,12 @@ else echo -n "$JWT" > /opt/testnet/build/el/jwtsecret + OTHER_OPTS="" + if [ "$CERC_ALLOW_UNPROTECTED_TXS" == "true" ]; then + # Allow for unprotected (non EIP155) txs to be submitted via RPC + OTHER_OPTS+=" --rpc.allow-unprotected-txs" + fi + $START_CMD \ --datadir="${CERC_ETH_DATADIR}" \ --bootnodes="${ENODE}" \ @@ -80,6 +86,7 @@ else --verbosity=${CERC_GETH_VERBOSITY:-3} \ --log.vmodule="${CERC_GETH_VMODULE}" \ --miner.etherbase="${ETHERBASE}" \ + ${OTHER_OPTS} \ & geth_pid=$! -- 2.45.2