diff --git a/ex_app_scripts/entrypoint.sh b/ex_app_scripts/entrypoint.sh index 86a32fe..f0ae227 100644 --- a/ex_app_scripts/entrypoint.sh +++ b/ex_app_scripts/entrypoint.sh @@ -16,6 +16,9 @@ fi /ex_app_scripts/init_pgsql.sh /ex_app_scripts/set_workers_num.sh +# Reloading environment variables to reflect changes if were +. /etc/environment + # Run all arguments after "first" in the background main_command=$1 shift # Remove the first argument, which is "the name of main binary" diff --git a/ex_app_scripts/init_pgsql.sh b/ex_app_scripts/init_pgsql.sh index 2e3e5ba..7a7ac19 100644 --- a/ex_app_scripts/init_pgsql.sh +++ b/ex_app_scripts/init_pgsql.sh @@ -79,9 +79,6 @@ else fi echo "DATABASE_URL was not set. It is now set to: $DATABASE_URL" - - # Reload environment variables - . /etc/environment else echo "DATABASE_URL is already set to: $DATABASE_URL" fi diff --git a/ex_app_scripts/set_workers_num.sh b/ex_app_scripts/set_workers_num.sh index cda24de..4e1703f 100644 --- a/ex_app_scripts/set_workers_num.sh +++ b/ex_app_scripts/set_workers_num.sh @@ -10,9 +10,6 @@ if [ -z "$NUM_WORKERS" ]; then fi echo "NUM_WORKERS was not set. It is now set to: $NUM_WORKERS" - - # Reload environment variables - . /etc/environment else echo "NUM_WORKERS is already set to: $NUM_WORKERS" fi