From 02f27ace40eb29ddc661c3c2c2deba5f6cb660d2 Mon Sep 17 00:00:00 2001 From: Georges-Antoine Assi Date: Sun, 17 Mar 2024 17:05:26 -0400 Subject: [PATCH] disable built in redis if env set --- docker/init_scripts/init | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docker/init_scripts/init b/docker/init_scripts/init index d9cc41b56..85320836f 100755 --- a/docker/init_scripts/init +++ b/docker/init_scripts/init @@ -107,7 +107,10 @@ cd /backend || { error_log "/backend directory doesn't seem to exist"; } # function definition done, lets start our main loop while true; do # Start redis server if we dont have a corresponding PID file - watchdog_process_pid bin redis-server + # and REDIS_HOST is not set (which would mean we're using an external redis) + if [[ -z "${REDIS_HOST}" ]]; then + watchdog_process_pid bin redis-server + fi # Run needed database migrations on startup, # but only if it was not successful since the last full docker container start