settings: added local_settings.

Signed-off-by: rscnt <rascnt@gmail.com>
This commit is contained in:
rascencio 2015-05-20 20:57:22 -06:00
parent 03777523f9
commit b77d1db911
3 changed files with 21 additions and 5 deletions

View file

View file

@ -0,0 +1,13 @@
from settings import SITE_ROOT
DEBUG = True
TEMPLATE_DEBUG = DEBUG
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'db_name',
'USER': 'username',
'PASSWORD': 'password',
}
}

View file

@ -10,12 +10,14 @@ For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.8/ref/settings/
"""
# -*- coding: utf-8 -*-
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os
import django.db.backends.postgresql_psycopg2
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
gettext = lambda s: s
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.8/howto/deployment/checklist/
@ -106,7 +108,8 @@ STATIC_URL = '/static/'
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
try:
from .settings_local import *
except ImportError as e:
pass
from local.local_settings import * # noqa
except ImportError:
logging.warning("No local_settings file found.")