From 3fbbe26c9e580fe39b9c66381ee18656db05604f Mon Sep 17 00:00:00 2001 From: Roy Crihfield Date: Fri, 9 Jun 2023 01:50:34 +0800 Subject: [PATCH 1/3] forward more vars for debugging forward CERC_GETH_VERBOSITY forward CERC_STATEDIFF_DB_LOG_STATEMENTS forward CERC_REMOTE_DEBUG --- app/data/compose/docker-compose-fixturenet-eth.yml | 2 +- app/data/compose/docker-compose-fixturenet-plugeth.yml | 2 +- app/data/compose/docker-compose-ipld-eth-server.yml | 2 +- app/data/config/fixturenet-eth/fixturenet-eth.env | 3 ++- app/data/stacks/fixturenet-eth-loaded/README.md | 2 +- app/deploy.py | 2 +- 6 files changed, 7 insertions(+), 6 deletions(-) diff --git a/app/data/compose/docker-compose-fixturenet-eth.yml b/app/data/compose/docker-compose-fixturenet-eth.yml index 530cd010..663b53c5 100644 --- a/app/data/compose/docker-compose-fixturenet-eth.yml +++ b/app/data/compose/docker-compose-fixturenet-eth.yml @@ -21,7 +21,7 @@ services: cap_add: - SYS_PTRACE environment: - CERC_REMOTE_DEBUG: "true" + CERC_REMOTE_DEBUG: ${CERC_REMOTE_DEBUG:-true} CERC_RUN_STATEDIFF: ${CERC_RUN_STATEDIFF:-detect} CERC_STATEDIFF_DB_NODE_ID: 1 CERC_SCRIPT_DEBUG: ${CERC_SCRIPT_DEBUG} diff --git a/app/data/compose/docker-compose-fixturenet-plugeth.yml b/app/data/compose/docker-compose-fixturenet-plugeth.yml index 4780574c..0664023c 100644 --- a/app/data/compose/docker-compose-fixturenet-plugeth.yml +++ b/app/data/compose/docker-compose-fixturenet-plugeth.yml @@ -20,7 +20,7 @@ services: cap_add: - SYS_PTRACE environment: - CERC_REMOTE_DEBUG: "true" + CERC_REMOTE_DEBUG: ${CERC_REMOTE_DEBUG:-true} CERC_RUN_STATEDIFF: "detect" CERC_STATEDIFF_DB_NODE_ID: 1 CERC_SCRIPT_DEBUG: ${CERC_SCRIPT_DEBUG} diff --git a/app/data/compose/docker-compose-ipld-eth-server.yml b/app/data/compose/docker-compose-ipld-eth-server.yml index ee787d5e..279dca77 100644 --- a/app/data/compose/docker-compose-ipld-eth-server.yml +++ b/app/data/compose/docker-compose-ipld-eth-server.yml @@ -26,7 +26,7 @@ services: PROM_HTTP_ADDR: "0.0.0.0" PROM_HTTP_PORT: "8090" LOGRUS_LEVEL: "debug" - CERC_REMOTE_DEBUG: "true" + CERC_REMOTE_DEBUG: ${CERC_REMOTE_DEBUG:-true} volumes: - type: bind source: ../config/ipld-eth-server/chain.json diff --git a/app/data/config/fixturenet-eth/fixturenet-eth.env b/app/data/config/fixturenet-eth/fixturenet-eth.env index ea56e2ec..2bf489ae 100644 --- a/app/data/config/fixturenet-eth/fixturenet-eth.env +++ b/app/data/config/fixturenet-eth/fixturenet-eth.env @@ -18,7 +18,8 @@ CERC_STATEDIFF_DB_NAME="cerc_testing" CERC_STATEDIFF_DB_USER="vdbm" CERC_STATEDIFF_DB_PASSWORD="password" CERC_STATEDIFF_DB_GOOSE_MIN_VER=${CERC_STATEDIFF_DB_GOOSE_MIN_VER:-18} -CERC_STATEDIFF_DB_LOG_STATEMENTS="false" +CERC_STATEDIFF_DB_LOG_STATEMENTS="${CERC_STATEDIFF_DB_LOG_STATEMENTS:-false}" CERC_STATEDIFF_WORKERS=2 CERC_GETH_VMODULE="statediff/*=5,rpc/*=5" +CERC_GETH_VERBOSITY=${CERC_GETH_VERBOSITY:-3} \ No newline at end of file diff --git a/app/data/stacks/fixturenet-eth-loaded/README.md b/app/data/stacks/fixturenet-eth-loaded/README.md index 09eab027..08ae1e37 100644 --- a/app/data/stacks/fixturenet-eth-loaded/README.md +++ b/app/data/stacks/fixturenet-eth-loaded/README.md @@ -1,4 +1,4 @@ -# fixturenet-eth +# fixturenet-eth-loaded A "loaded" version of fixturenet-eth, with all the bells and whistles enabled. diff --git a/app/deploy.py b/app/deploy.py index 3f769f3e..2b60b8d9 100644 --- a/app/deploy.py +++ b/app/deploy.py @@ -228,7 +228,7 @@ def _make_runtime_env(ctx): "CERC_HOST_UID": f"{os.getuid()}", "CERC_HOST_GID": f"{os.getgid()}" } - container_exec_env.update({"CERC_SCRIPT_DEBUG": "true"} if ctx.debug else {}) + container_exec_env.update({"CERC_SCRIPT_DEBUG": "true", "CERC_REMOTE_DEBUG": "true"} if ctx.debug else {}) return container_exec_env -- 2.45.2 From 4954362a714e4c320629ebcf8ce1913b8e0d2776 Mon Sep 17 00:00:00 2001 From: Roy Crihfield Date: Thu, 6 Jul 2023 12:34:24 +0800 Subject: [PATCH 2/3] fix env var --- app/data/compose/docker-compose-ipld-eth-server.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/data/compose/docker-compose-ipld-eth-server.yml b/app/data/compose/docker-compose-ipld-eth-server.yml index 279dca77..a408dff1 100644 --- a/app/data/compose/docker-compose-ipld-eth-server.yml +++ b/app/data/compose/docker-compose-ipld-eth-server.yml @@ -25,7 +25,7 @@ services: PROM_HTTP: "true" PROM_HTTP_ADDR: "0.0.0.0" PROM_HTTP_PORT: "8090" - LOGRUS_LEVEL: "debug" + LOG_LEVEL: "debug" CERC_REMOTE_DEBUG: ${CERC_REMOTE_DEBUG:-true} volumes: - type: bind -- 2.45.2 From eac594a98349a374355f9f32519be09c7d3bffdd Mon Sep 17 00:00:00 2001 From: Roy Crihfield Date: Tue, 18 Jul 2023 02:22:05 +0800 Subject: [PATCH 3/3] remote flag can be set from env --- app/deploy.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/deploy.py b/app/deploy.py index 2b60b8d9..3f769f3e 100644 --- a/app/deploy.py +++ b/app/deploy.py @@ -228,7 +228,7 @@ def _make_runtime_env(ctx): "CERC_HOST_UID": f"{os.getuid()}", "CERC_HOST_GID": f"{os.getgid()}" } - container_exec_env.update({"CERC_SCRIPT_DEBUG": "true", "CERC_REMOTE_DEBUG": "true"} if ctx.debug else {}) + container_exec_env.update({"CERC_SCRIPT_DEBUG": "true"} if ctx.debug else {}) return container_exec_env -- 2.45.2