You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# handle legacy DB_SSL configuration, as we couldn't conditionally template that in docker-compose.yml
2
-
if [[ -v DB_SSL && "${DB_SSL}" = "true" ]]; then
3
-
if [[ -v PGSSLMODE && -v PGREQUIRESSL ]]; then
4
-
export PGSSLMODE="require"
5
-
else
6
-
echo "Fatal: legacy 'DB_SSL=true' specified, but PGSSLMODE or PGREQUIRESSL has already been set. To resolve ambiguity, remove 'DB_SSL=true' from your .env file." > /dev/stderr
7
-
exit 100
1
+
# if the PGSERVICE mechanism — libpq named configurations (specified through this env var)
2
+
# sourced from a file (referenced through PGSERVICEFILE env var) is used, leave everything be.
3
+
if ! [[ -v PGSERVICE ]]; then
4
+
5
+
# handle legacy DB_SSL configuration, as we couldn't conditionally template that in docker-compose.yml
6
+
if [[ -v DB_SSL && "${DB_SSL}" = "true" ]]; then
7
+
if [[ -v PGSSLMODE && -v PGREQUIRESSL ]]; then
8
+
export PGSSLMODE="require"
9
+
else
10
+
echo "Fatal: legacy 'DB_SSL=true' specified, but PGSSLMODE or PGREQUIRESSL has already been set. To resolve ambiguity, remove 'DB_SSL=true' from your .env file." > /dev/stderr
11
+
exit 100
12
+
fi
8
13
fi
9
-
fi
10
14
11
-
# handle other legacy DB_* configuration, and fill in our defaults if nothing is specified
12
-
# When these PG* variables are _defined_ (even if _empty_), they will be left as-is.
0 commit comments