settings: activate south with sqlite if FORCE_SOUTH is defined in the environment
This commit is contained in:
parent
fca12ab15e
commit
87af9df45a
8
README
8
README
|
@ -130,3 +130,11 @@ MAX_ENTITY_FILTER_DEPTH
|
|||
USE_PDF_VIEWER
|
||||
|
||||
Utiliser la visionneuse de PDF, par défaut False.
|
||||
|
||||
Environment
|
||||
-----------
|
||||
|
||||
FORCE_SOUTH
|
||||
|
||||
If this variable is defined in the environment, you can use south with
|
||||
sqlite.
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
# Django settings for polynum project.
|
||||
|
||||
import os
|
||||
import os.path
|
||||
import django.conf.global_settings as DEFAULT_SETTINGS
|
||||
from django.core.urlresolvers import reverse_lazy
|
||||
|
@ -218,7 +219,7 @@ except:
|
|||
pass
|
||||
|
||||
# use South, unless if database is sqlite3
|
||||
if DATABASES['default']['ENGINE'] != 'django.db.backends.sqlite3':
|
||||
if DATABASES['default']['ENGINE'] != 'django.db.backends.sqlite3' or 'FORCE_SOUTH' in os.environ:
|
||||
INSTALLED_APPS = ('south',) + INSTALLED_APPS
|
||||
|
||||
# CAS
|
||||
|
|
Reference in New Issue