From c7cae8b6cdc2590392cb639b8a7a65d275d347b4 Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Mon, 8 Apr 2024 17:32:48 +0530 Subject: [PATCH 1/3] Update init script to enable prometheus metrics --- init.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/init.sh b/init.sh index 1044f67a..89a3ee1c 100755 --- a/init.sh +++ b/init.sh @@ -100,6 +100,11 @@ if [ "$1" == "clean" ] || [ ! -d "$HOME/.laconicd/data/blockstore.db" ]; then $HOME/.laconicd/config/config.toml fi + # Enable telemetry (prometheus metrics: http://localhost:1317/metrics?format=prometheus) + sed -i 's/enabled = false/enabled = true/g' $HOME/.laconicd/config/app.toml + sed -i 's/prometheus-retention-time = 0/prometheus-retention-time = 60/g' $HOME/.laconicd/config/app.toml + sed -i 's/prometheus = false/prometheus = true/g' $HOME/.laconicd/config/config.toml + # Allocate genesis accounts (cosmos formatted addresses) laconicd add-genesis-account $KEY 100000000000000000000000000aphoton --keyring-backend $KEYRING -- 2.45.2 From 7ca24ce1411ffb0379efdc0a456c71cc79c26493 Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Wed, 10 Apr 2024 19:36:10 +0530 Subject: [PATCH 2/3] Increase sleep while running integration tests --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index dbc5b767..4595330a 100644 --- a/Makefile +++ b/Makefile @@ -337,7 +337,7 @@ test-import: go test -run TestImporterTestSuite -timeout=20m -v --vet=off github.com/cerc-io/laconicd/tests/importer test-rpc: - ./scripts/integration-test-all.sh -t "rpc" -q 1 -z 1 -s 2 -m "rpc" -r "true" + ./scripts/integration-test-all.sh -t "rpc" -q 1 -z 1 -s 10 -m "rpc" -r "true" run-integration-tests: @nix-shell ./tests/integration_tests/shell.nix --run ./scripts/run-integration-tests.sh -- 2.45.2 From 1cb33cc0925195ff79ee46d1de83bf7017c75270 Mon Sep 17 00:00:00 2001 From: Prathamesh Musale Date: Thu, 11 Apr 2024 11:39:08 +0530 Subject: [PATCH 3/3] Handle config update for ostype Darwin --- init.sh | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/init.sh b/init.sh index 89a3ee1c..c063b7e2 100755 --- a/init.sh +++ b/init.sh @@ -101,9 +101,15 @@ if [ "$1" == "clean" ] || [ ! -d "$HOME/.laconicd/data/blockstore.db" ]; then fi # Enable telemetry (prometheus metrics: http://localhost:1317/metrics?format=prometheus) - sed -i 's/enabled = false/enabled = true/g' $HOME/.laconicd/config/app.toml - sed -i 's/prometheus-retention-time = 0/prometheus-retention-time = 60/g' $HOME/.laconicd/config/app.toml - sed -i 's/prometheus = false/prometheus = true/g' $HOME/.laconicd/config/config.toml + if [[ "$OSTYPE" == "darwin"* ]]; then + sed -i '' 's/enabled = false/enabled = true/g' $HOME/.laconicd/config/app.toml + sed -i '' 's/prometheus-retention-time = 0/prometheus-retention-time = 60/g' $HOME/.laconicd/config/app.toml + sed -i '' 's/prometheus = false/prometheus = true/g' $HOME/.laconicd/config/config.toml + else + sed -i 's/enabled = false/enabled = true/g' $HOME/.laconicd/config/app.toml + sed -i 's/prometheus-retention-time = 0/prometheus-retention-time = 60/g' $HOME/.laconicd/config/app.toml + sed -i 's/prometheus = false/prometheus = true/g' $HOME/.laconicd/config/config.toml + fi # Allocate genesis accounts (cosmos formatted addresses) laconicd add-genesis-account $KEY 100000000000000000000000000aphoton --keyring-backend $KEYRING -- 2.45.2