Commit 630ad37c authored by Christoph Berg's avatar Christoph Berg

Fix duplicate install file which caused pgbouncer.ini to get lost.

* Fix duplicate install file which caused pgbouncer.ini to get lost.
* Fix connect test not to rely on userlist.txt to exist.
* Bump to compat 9.
parent 20dd8ec0
pgbouncer (1.5.4-6) UNRELEASED; urgency=low
pgbouncer (1.5.4-6) unstable; urgency=low
* Fix duplicate install file which caused pgbouncer.ini to get lost.
* Fix connect test not to rely on userlist.txt to exist.
* Bump to compat 9.
* Set team as Maintainer.
-- Christoph Berg <christoph.berg@credativ.de> Wed, 02 Jul 2014 10:40:39 +0200
-- Christoph Berg <myon@debian.org> Wed, 16 Jul 2014 17:48:55 +0300
pgbouncer (1.5.4-5) unstable; urgency=low
......
......@@ -4,7 +4,7 @@ Uploaders: Bernd Zeimetz <bzed@debian.org>, Christoph Berg <myon@debian.org>, Pe
Section: database
Priority: optional
Standards-Version: 3.9.5
Build-Depends: cdbs, debhelper (>= 7), libevent-dev (>= 1.3b), asciidoc, autotools-dev, xmlto, python
Build-Depends: cdbs, debhelper (>= 9), libevent-dev (>= 1.3b), asciidoc, autotools-dev, xmlto, python
Homepage: http://pgfoundry.org/projects/pgbouncer/
Vcs-Git: git://anonscm.debian.org/pkg-postgresql/pgbouncer.git
Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-postgresql/pgbouncer.git
......
etc/pgbouncer.ini /etc/pgbouncer/
etc/mkauth.py usr/share/pgbouncer/
etc/pgbouncer.ini etc/pgbouncer
etc/mkauth.py usr/share/pgbouncer
......@@ -19,6 +19,7 @@ set -e
CLEAN_FILES="/etc/pgbouncer/pgbouncer.ini /etc/pgbouncer/userlist.txt /etc/default/pgbouncer"
cleanup () {
/etc/init.d/pgbouncer stop || :
rm -f /etc/pgbouncer/userlist.txt output
for f in $CLEAN_FILES; do
test -f $f.adt-save && mv -f $f.adt-save $f
done
......@@ -27,7 +28,8 @@ trap cleanup 0 2 3 15
# set up minimal pgbouncer config
sed -i.adt-save -e '/\[databases\]/ apostgres =' /etc/pgbouncer/pgbouncer.ini
cp -a /etc/pgbouncer/userlist.txt /etc/pgbouncer/userlist.txt.adt-save
test -e /etc/pgbouncer/userlist.txt &&
cp -a /etc/pgbouncer/userlist.txt /etc/pgbouncer/userlist.txt.adt-save
echo "\"$PGUSER\" \"$PGPASSWORD\"" >> /etc/pgbouncer/userlist.txt
sed -i.adt-save -e 's/START=0/START=1/' /etc/default/pgbouncer
......@@ -43,9 +45,10 @@ echo "Trying online restart ..."
(
echo "SELECT 3+4;"
/etc/init.d/pgbouncer restart > /dev/null
sleep 1
echo "SELECT 5+6;"
) | psql -p 6432 -d postgres -tA > output
cat output
[ "$(cat output)" = "7
11" ]
echo "Result OK"
rm -f output
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment