diff --git a/10/root/usr/share/container-scripts/postgresql/common.sh b/10/root/usr/share/container-scripts/postgresql/common.sh index d5e6d579..445dee0a 100644 --- a/10/root/usr/share/container-scripts/postgresql/common.sh +++ b/10/root/usr/share/container-scripts/postgresql/common.sh @@ -250,6 +250,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi diff --git a/12/root/usr/share/container-scripts/postgresql/common.sh b/12/root/usr/share/container-scripts/postgresql/common.sh index 0d0d8ab5..a78fabc0 100644 --- a/12/root/usr/share/container-scripts/postgresql/common.sh +++ b/12/root/usr/share/container-scripts/postgresql/common.sh @@ -250,6 +250,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi diff --git a/13/root/usr/share/container-scripts/postgresql/common.sh b/13/root/usr/share/container-scripts/postgresql/common.sh index cfa6997f..f16e0a91 100644 --- a/13/root/usr/share/container-scripts/postgresql/common.sh +++ b/13/root/usr/share/container-scripts/postgresql/common.sh @@ -250,6 +250,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi diff --git a/14/root/usr/share/container-scripts/postgresql/common.sh b/14/root/usr/share/container-scripts/postgresql/common.sh index 97508b19..9dd4444e 100644 --- a/14/root/usr/share/container-scripts/postgresql/common.sh +++ b/14/root/usr/share/container-scripts/postgresql/common.sh @@ -250,6 +250,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi diff --git a/15/root/usr/share/container-scripts/postgresql/common.sh b/15/root/usr/share/container-scripts/postgresql/common.sh index 6963e78a..6e1eca10 100644 --- a/15/root/usr/share/container-scripts/postgresql/common.sh +++ b/15/root/usr/share/container-scripts/postgresql/common.sh @@ -250,6 +250,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi diff --git a/src/root/usr/share/container-scripts/postgresql/common.sh b/src/root/usr/share/container-scripts/postgresql/common.sh index 592b01d8..10a8388c 100644 --- a/src/root/usr/share/container-scripts/postgresql/common.sh +++ b/src/root/usr/share/container-scripts/postgresql/common.sh @@ -251,6 +251,7 @@ migrate_db () # Migration path. ( + set -o pipefail if [ ${POSTGRESQL_MIGRATION_IGNORE_ERRORS-no} = no ]; then echo '\set ON_ERROR_STOP on' fi