Merge pull request #3 from teohhanhui/patch-1

Test the specified POSTGRES_DB
This commit is contained in:
Tianon Gravi 2017-03-30 10:11:04 -07:00 committed by GitHub
commit d1f10080c5
1 changed files with 2 additions and 0 deletions

View File

@ -3,12 +3,14 @@ set -eo pipefail
host="$(hostname --ip-address || echo '127.0.0.1')"
user="${POSTGRES_USER:-postgres}"
db="${POSTGRES_DB:-$POSTGRES_USER}"
export PGPASSWORD="${POSTGRES_PASSWORD:-}"
args=(
# force postgres to not use the local unix socket (test "external" connectibility)
--host "$host"
--username "$user"
--dbname "$db"
--quiet --no-align --tuples-only
)