Added db.Ping to ensure good connection to Postgres