Added ConnectionURL along with ConnectionString

This commit is contained in:
vishalnayak
2015-10-02 23:47:10 -04:00
parent af61803256
commit 8dc5bdf0e3
4 changed files with 28 additions and 4 deletions

View File

@@ -76,6 +76,9 @@ func (b *backend) DB(s logical.Storage) (*sql.DB, error) {
}
conn := connConfig.ConnectionString
if len(conn) == 0 {
conn = connConfig.ConnectionURL
}
// Ensure timezone is set to UTC for all the conenctions
if strings.HasPrefix(conn, "postgres://") || strings.HasPrefix(conn, "postgresql://") {