diff --git a/10/alpine/docker-entrypoint.sh b/10/alpine/docker-entrypoint.sh index 93cfeeee75..6dce8a15c6 100755 --- a/10/alpine/docker-entrypoint.sh +++ b/10/alpine/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/10/docker-entrypoint.sh b/10/docker-entrypoint.sh index 4b475f999f..93ee4fba4d 100755 --- a/10/docker-entrypoint.sh +++ b/10/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/11/alpine/docker-entrypoint.sh b/11/alpine/docker-entrypoint.sh index 93cfeeee75..6dce8a15c6 100755 --- a/11/alpine/docker-entrypoint.sh +++ b/11/alpine/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/11/docker-entrypoint.sh b/11/docker-entrypoint.sh index 4b475f999f..93ee4fba4d 100755 --- a/11/docker-entrypoint.sh +++ b/11/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.4/alpine/docker-entrypoint.sh b/9.4/alpine/docker-entrypoint.sh index 5e7ba0e7cb..8f9cfcc92c 100755 --- a/9.4/alpine/docker-entrypoint.sh +++ b/9.4/alpine/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.4/docker-entrypoint.sh b/9.4/docker-entrypoint.sh index b963b3d9f1..3f984a1649 100755 --- a/9.4/docker-entrypoint.sh +++ b/9.4/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.5/alpine/docker-entrypoint.sh b/9.5/alpine/docker-entrypoint.sh index 5e7ba0e7cb..8f9cfcc92c 100755 --- a/9.5/alpine/docker-entrypoint.sh +++ b/9.5/alpine/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.5/docker-entrypoint.sh b/9.5/docker-entrypoint.sh index b963b3d9f1..3f984a1649 100755 --- a/9.5/docker-entrypoint.sh +++ b/9.5/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.6/alpine/docker-entrypoint.sh b/9.6/alpine/docker-entrypoint.sh index 5e7ba0e7cb..8f9cfcc92c 100755 --- a/9.6/alpine/docker-entrypoint.sh +++ b/9.6/alpine/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/9.6/docker-entrypoint.sh b/9.6/docker-entrypoint.sh index b963b3d9f1..3f984a1649 100755 --- a/9.6/docker-entrypoint.sh +++ b/9.6/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN' diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh index 4b475f999f..93ee4fba4d 100755 --- a/docker-entrypoint.sh +++ b/docker-entrypoint.sh @@ -84,6 +84,19 @@ if [ "$1" = 'postgres' ]; then # messes it up if [ -n "$POSTGRES_PASSWORD" ]; then authMethod=md5 + + if [ "${#POSTGRES_PASSWORD}" -ge 100 ]; then + cat >&2 <<-'EOWARN' + + WARNING: The supplied POSTGRES_PASSWORD is 100+ characters. + + This will not work if used via PGPASSWORD with "psql". + + https://www.postgresql.org/message-id/flat/E1Rqxp2-0004Qt-PL%40wrigleys.postgresql.org (BUG #6412) + https://github.com/docker-library/postgres/issues/507 + + EOWARN + fi else # The - option suppresses leading tabs but *not* spaces. :) cat >&2 <<-'EOWARN'