grAPES/grapes/settings_local.py.sample

76 lignes
2.2 KiB
Python

# -*- mode: python ; coding: utf-8 -*-
# Django local settings for grapes project. (always_data)
from settings_default import *
DEBUG = True
TEMPLATE_DEBUG = DEBUG
DJ_DEBUG_TOOLBAR = False
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
# Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'grapes', # Or path to database file if using sqlite3.
'USER': 'grapes', # Not used with sqlite3.
'PASSWORD': 'grapes', # Not used with sqlite3.
'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.
}
}
# Make this unique, and don't share it with anybody.
#SECRET_KEY = 'xuklg&i06jh1-hms4gbl)6!ewjta&r%**8(91kx^@wmd-t_l-h'
ADMINS = (
# ('Your Name', 'your_email@domain.com'),
)
## debug_toolbar config
INTERNAL_IPS = ('127.0.0.1','192.168.101.51', '212.198.6.129')
DEBUG_TOOLBAR_PANELS = (
'debug_toolbar.panels.version.VersionDebugPanel',
'debug_toolbar.panels.timer.TimerDebugPanel',
'debug_toolbar.panels.settings_vars.SettingsVarsDebugPanel',
'debug_toolbar.panels.headers.HeaderDebugPanel',
'debug_toolbar.panels.request_vars.RequestVarsDebugPanel',
'debug_toolbar.panels.template.TemplateDebugPanel',
'debug_toolbar.panels.sql.SQLDebugPanel',
'debug_toolbar.panels.signals.SignalDebugPanel',
'debug_toolbar.panels.logger.LoggingPanel',
)
DEBUG_TOOLBAR_CONFIG = {
'INTERCEPT_REDIRECTS' : False,
}
if DJ_DEBUG_TOOLBAR:
MIDDLEWARE_CLASSES = (
'debug_toolbar.middleware.DebugToolbarMiddleware',
) + MIDDLEWARE_CLASSES
INSTALLED_APPS = INSTALLED_APPS + ('debug_toolbar',)
#LOGIN_REDIRECT_URL = '/'
#REQUIRE_LOGIN_PATH = '/accounts/login/'
# For a sublocation:
SUBLOCATION = ''
for item in (
'LOGIN_URL',
'LOGIN_REDIRECT_URL',
'STATIC_MEDIA_URL',
'STATIC_URL',
'MEDIA_URL'):
if item in globals():
globals()[item] = SUBLOCATION + globals()[item]
#SESSION_COOKIE_PATH = SUBLOCATION
#CSRF_COOKIE_PATH = SUBLOCATION
#24h = 86400 secondes
SESSION_COOKIE_AGE=86400
SERVER_EMAIL='grapes@fqdn'
EMAIL_HOST = '' # a SMTP server
EMAIL_PORT = 25
# EOF