From 34e1863af3f342c3c08f845515b5b761f78f1978 Mon Sep 17 00:00:00 2001 From: bencord0 Date: Sun, 17 Jun 2012 16:09:29 +0200 Subject: [PATCH] RedHat's OpenShift platform uses the 'postgresql' scheme. Note: Use .config(env=OPENSHIFT_DB_URL) or some other way to set DATABASE_URL=$OPENSHIFT_DB_URL --- dj_database_url.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dj_database_url.py b/dj_database_url.py index 4b09a53..1c86eea 100644 --- a/dj_database_url.py +++ b/dj_database_url.py @@ -40,7 +40,7 @@ def parse(url): 'PORT': url.port, }) - if url.scheme == 'postgres': + if url.scheme == 'postgres' or url.scheme == 'postgresql': config['ENGINE'] = 'django.db.backends.postgresql_psycopg2' if url.scheme == 'postgis':