From ea16dfc857220ed50992c46653e100ce848d87be Mon Sep 17 00:00:00 2001 From: "roman@osmosis.team" Date: Fri, 27 Oct 2023 15:58:26 -0400 Subject: [PATCH] test mainnet for Grant --- app/main.go | 8 ++++---- start | 23 +++++++++++++++++++++++ 2 files changed, 27 insertions(+), 4 deletions(-) create mode 100755 start diff --git a/app/main.go b/app/main.go index 3a7884ba9..8601b2ef9 100644 --- a/app/main.go +++ b/app/main.go @@ -124,10 +124,10 @@ func main() { go func() { defer workerWaitGroup.Done() - err := updatePoolStateWorker(ctx, exitChan, chainClient, poolsRepository) - if err != nil { - panic(err) - } + // err := updatePoolStateWorker(ctx, exitChan, chainClient, poolsRepository) + // if err != nil { + // panic(err) + // } }() err = e.Start(viper.GetString("server.address")) diff --git a/start b/start new file mode 100755 index 000000000..94c00fd2e --- /dev/null +++ b/start @@ -0,0 +1,23 @@ +#!/bin/bash +# This script is used for executing the process at different rates. +# When you are developing locally and running the docker-compose you need to sleep +# If you don't you will have to start the process like 3 times before it will connect to redis. +# This takes the debug variable from pipeline and determines if it needs to be used for the kubernetes deployments. +# The docker-compose automatically sets it to debug. +# One thing to add is to make the code load its debug value from this as well. +# When its Kubernetes deployment you can't mount directly to osmosis dir so we have to copy if the file and directory exist. +echo "Copy the config from the mount point to the osmosis application directory." +cp /osmosis-mount/config.json /osmosis/config.json || echo "not kubernetes deployment" +if [ "${DEBUG}" == "true" ]; then + echo "look at contents of the osmosis directory." + ls -lah /osmosis/ + echo "Log the config for debugging" + cat /osmosis/config.json + echo "keep node alive on failure for debugging" >> status + echo "sleep for 30 seconds to let other services start" + sleep 30 + echo "start process with debug and keep container running for troubleshooting purposes." + /bin/sqsd || echo "failed to start" && tail -f status +else + /bin/sqsd +fi \ No newline at end of file