openbackloggery/collection/collection/settings.py

31 lines
819 B
Python
Raw Normal View History

2017-08-16 20:00:41 +00:00
"""
This is a django-split-settings main file.
For more information read this:
https://github.com/sobolevn/django-split-settings
2017-08-16 20:00:41 +00:00
Default environment is `developement`.
2017-08-16 20:00:41 +00:00
To change settings file:
`DJANGO_ENV=production python manage.py runserver`
2017-08-16 20:00:41 +00:00
"""
from split_settings.tools import optional, include
from os import environ
2017-08-16 20:00:41 +00:00
ENV = environ.get('DJANGO_ENV') or 'development'
2017-08-16 20:00:41 +00:00
base_settings = [
'components/common.py', # standard django settings
'components/database.py', # SQLite 3
'components/i18n.py', # Internationalisation and localization
'components/api.py', # API (django rest framework) + CORS
2017-08-16 20:00:41 +00:00
# Select the right env:
'environments/%s.py' % ENV,
# Optionally override some settings:
optional('environments/local_settings.py'),
2017-08-16 20:00:41 +00:00
]
# Include settings:
include(*base_settings)