debian/tests/ssl: Force md5 auth if cl-postmodern is too old.

This commit is contained in:
Christoph Berg 2021-12-22 18:08:21 +01:00
parent 0925960989
commit a94a0a3327
3 changed files with 10 additions and 3 deletions

1
debian/changelog vendored
View File

@ -2,6 +2,7 @@ pgloader (3.6.3-1) unstable; urgency=medium
* New upstream version.
* Remove cl-pgloader, deprecated upstream.
* debian/tests/ssl: Force md5 auth if cl-postmodern is too old.
-- Christoph Berg <myon@debian.org> Tue, 21 Dec 2021 10:09:53 +0100

View File

@ -1,3 +1,3 @@
Depends: pgloader, ca-certificates, postgresql
Depends: pgloader, ca-certificates, cl-postmodern, postgresql
Tests: ssl
Restrictions: allow-stderr, needs-root

10
debian/tests/ssl vendored
View File

@ -4,9 +4,15 @@
set -eux
trap "rm -rf /tmp/pgloader" 0 2 3 15
trap "rm -rf /tmp/pgloader" EXIT
pg_virtualenv <<-'EOF'
# check if cl-postmodern is new enough to support scram-sha-256
postmodern=$(dpkg-query --show --showformat='${Version}' cl-postmodern)
if dpkg --compare-versions "$postmodern" lt 20200101; then
AUTH="-i--auth-local=trust -i--auth-host=md5"
fi
pg_virtualenv ${AUTH:-} <<-'EOF'
set -eux
# force SSL connection