Fix stunnel idle dyno crash

stunnel connection to RDS crashes after going idle

https://github.com/heroku/heroku-buildpack-pgbouncer/issues/30

Trying suggestion from thread in issue.
http://www.helveticode.com/rds-postgresql-with-stunnel/
https://forums.aws.amazon.com/message.jspa?messageID=505895

I deployed this fork to the 1X web dyno that was failing before when hitting my Amazon RDS postgres instance. Waited 1.5 hours and confirmed dyno was sleeping in heroku dashboard.

When I ran my automation test against the dyno, the web dyno woke and connected successfully to my rds instance.

2014-12-17T22:06:10.636586+00:00 heroku[web.1]: Unidling
2014-12-17T22:06:10.636866+00:00 heroku[web.1]: State changed from down to starting
2014-12-17T22:06:19.963809+00:00 heroku[web.1]: Starting process with command `bin/start-pgbouncer-stunnel newrelic-admin run-program python ./manage.py run_gunicorn -b "0.0.0.0:8388" -w 1 -t 1801 --log-level INFO`
2014-12-17T22:06:20.695520+00:00 app[web.1]: buildpack=pgbouncer at=config-gen-start
2014-12-17T22:06:20.695144+00:00 app[web.1]: buildpack=pgbouncer at=pgbouncer-enabled
2014-12-17T22:06:20.868426+00:00 app[web.1]: Setting MY_DATABASE_URL_DB1_PGBOUNCER config var
2014-12-17T22:06:21.033687+00:00 app[web.1]: buildpack=pgbouncer at=app-start
2014-12-17T22:06:21.104496+00:00 app[web.1]: 2014-12-17 22:06:21.104 45 LOG listening on 127.0.0.1:6000
2014-12-17T22:06:21.104582+00:00 app[web.1]: 2014-12-17 22:06:21.104 45 LOG listening on unix:/tmp/.s.PGSQL.6000
2014-12-17T22:06:21.104611+00:00 app[web.1]: 2014-12-17 22:06:21.104 45 LOG process up: pgbouncer 1.5.4, libevent 1.4.13-stable (epoll), adns: libc-2.11
2014-12-17T22:06:21.021542+00:00 app[web.1]: buildpack=pgbouncer at=config-gen-end
2014-12-17T22:06:21.021648+00:00 app[web.1]: buildpack=pgbouncer at=config-gen-override MY_DATABASE_URL_DB1
2014-12-17T22:06:21.030178+00:00 app[web.1]: buildpack=pgbouncer at=stunnel-launched pid=41 signal=SIGINT
2014-12-17T22:06:21.030288+00:00 app[web.1]: buildpack=pgbouncer at=stunnel-start
2014-12-17T22:06:21.031039+00:00 app[web.1]: buildpack=pgbouncer at=pgbouncer-launched pid=42 signal=SIGINT
2014-12-17T22:06:21.031244+00:00 app[web.1]: buildpack=pgbouncer at=pgbouncer-start
2014-12-17T22:06:21.031940+00:00 app[web.1]: buildpack=pgbouncer at=app-launched pid=44
2014-12-17T22:06:21.049405+00:00 app[web.1]: 2014.12.17 22:06:21 LOG5[43]: stunnel 5.02 on x86_64-unknown-linux-gnu platform
2014-12-17T22:06:21.049417+00:00 app[web.1]: 2014.12.17 22:06:21 LOG5[43]: Compiled/running with OpenSSL 0.9.8k 25 Mar 2009
2014-12-17T22:06:21.049419+00:00 app[web.1]: 2014.12.17 22:06:21 LOG5[43]: Threading:PTHREAD Sockets:POLL,IPv6 SSL:ENGINE,OCSP
2014-12-17T22:06:21.049437+00:00 app[web.1]: 2014.12.17 22:06:21 LOG5[43]: Reading configuration from file vendor/stunnel/stunnel-pgbouncer.conf
2014-12-17T22:06:21.049439+00:00 app[web.1]: 2014.12.17 22:06:21 LOG5[43]: Configuration successful
2014-12-17T22:06:21.103376+00:00 app[web.1]: 2014-12-17 22:06:21.103 45 LOG File descriptor limit: 10000 (H:10000), max_client_conn: 20, max fds possible: 30
....
2014-12-17T22:06:22.237633+00:00 app[web.1]: 2014-12-17 22:06:22 [46] [INFO] Listening at: http://0.0.0.0:8388 (46)
2014-12-17T22:06:22.237723+00:00 app[web.1]: 2014-12-17 22:06:22 [46] [INFO] Using worker: sync
2014-12-17T22:06:22.258272+00:00 app[web.1]: 2014-12-17 22:06:22 [55] [INFO] Booting worker with pid: 55
2014-12-17T22:06:22.579797+00:00 heroku[web.1]: State changed from starting to up
....
2014-12-17T22:06:25.916867+00:00 app[web.1]: 2014.12.17 22:06:25 LOG5[58]: Service [MY_DATABASE_URL_DB1] accepted connection from unnamed socket
 request_id=a6a7341b-7313-46a2-b1b4-c16e1fa7366a fwd="208.185.21.146" dyno=web.1 connect=1ms service=718ms status=302 bytes=253
2014-12-17T22:06:25.919813+00:00 app[web.1]: 2014.12.17 22:06:25 LOG5[58]: s_connect: connected xxxxxxxxxx:5432
2014-12-17T22:06:25.919882+00:00 app[web.1]: 2014.12.17 22:06:25 LOG5[58]: Service [MY_DATABASE_URL_DB1] connected remote server from xxxxxxxxxxxxxxx:22656
2014-12-17T22:06:26.043362+00:00 app[web.1]: 2014-12-17 22:06:26.043 45 LOG C-0xc23df0: db1/my_user@127.0.0.1:31607 closing because: client close request (age=0)