From: Rafael dos Santos Silva Date: Wed, 19 Apr 2023 20:02:28 +0000 (-0300) Subject: DEV: Wait up to 10 minutes for safe PG stop (#709) X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=d54cc57f5fe7910db77cd92cfe40f2e011135bac;p=discourse_docker.git DEV: Wait up to 10 minutes for safe PG stop (#709) Over the years we had LOTS of cases of PostgreSQL instances that weren't stopped properly. This gives PG more time to handle it's shutdown cleanly on the worst case, but will still shutdown fast in normal cases. --- diff --git a/launcher b/launcher index c6ecda9..8a989b8 100755 --- a/launcher +++ b/launcher @@ -521,7 +521,7 @@ run_stop() { then ( set -x - $docker_path stop -t 30 $config + $docker_path stop -t 600 $config ) else echo "$config was not started !" @@ -817,7 +817,7 @@ case "$command" in echo "Stopping old container" ( set -x - $docker_path stop -t 60 $config + $docker_path stop -t 600 $config ) fi @@ -838,7 +838,7 @@ case "$command" in destroy) - (set -x; $docker_path stop -t 10 $config && $docker_path rm $config) || (echo "$config was not found" && exit 0) + (set -x; $docker_path stop -t 600 $config && $docker_path rm $config) || (echo "$config was not found" && exit 0) exit 0 ;; esac