4
4
DIRNAME = os.path.abspath(os.path.dirname(__file__))
8
7
TEMPLATE_DEBUG = DEBUG
11
('Bash One-Liners DEV', 'info@bashoneliners.com'),
10
# ('Your Name', 'your_email@domain.com'),
18
'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
17
'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
19
18
'NAME': 'sqlite3.db', # Or path to database file if using sqlite3.
20
19
'USER': '', # Not used with sqlite3.
21
20
'PASSWORD': '', # Not used with sqlite3.
47
46
# calendars according to the current locale
50
# Absolute filesystem path to the directory that will hold user-uploaded files.
51
# Example: "/home/media/media.lawrence.com/media/"
52
MEDIA_ROOT = os.path.join(DIRNAME, 'www')
49
# Absolute path to the directory that holds media.
50
# Example: "/home/media/media.lawrence.com/"
51
MEDIA_ROOT = os.path.join(DIRNAME, 'media/www/')
54
53
# URL that handles the media served from MEDIA_ROOT. Make sure to use a
54
# trailing slash if there is a path component (optional in other cases).
55
# Examples: "http://media.lawrence.com", "http://example.com/media/"
56
MEDIA_URL = '/media/www/'
58
# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
56
# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
59
# Absolute path to the directory static files should be collected to.
60
# Don't put anything in this directory yourself; store your static files
61
# in apps' "static/" subdirectories and in STATICFILES_DIRS.
62
# Example: "/home/media/media.lawrence.com/static/"
65
# URL prefix for static files.
66
# Example: "http://media.lawrence.com/static/"
67
STATIC_URL = '/media/'
69
# URL prefix for admin static files -- CSS, JavaScript and images.
70
# Make sure to use a trailing slash.
71
# Examples: "http://foo.com/static/admin/", "/static/admin/".
72
ADMIN_MEDIA_PREFIX = '/media/admin/'
74
# Additional locations of static files
76
# Put strings here, like "/home/html/static" or "C:/www/django/static".
77
# Always use forward slashes, even on Windows.
78
# Don't forget to use absolute paths, not relative paths.
79
os.path.join(DIRNAME, 'media'),
82
# List of finder classes that know how to find static files in
84
STATICFILES_FINDERS = (
85
'django.contrib.staticfiles.finders.FileSystemFinder',
86
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
87
# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
60
# Examples: "http://foo.com/media/", "/media/".
61
ADMIN_MEDIA_PREFIX = '/admin_media/'
90
63
# Make this unique, and don't share it with anybody.
91
64
SECRET_KEY = '06@udwbt7b*dxb2cpq+ly8b1kn-(5bb2jae949%*yz48t-$+dm'
105
78
'django.contrib.messages.middleware.MessageMiddleware',
108
AUTH_PROFILE_MODULE = 'oneliners.models.HackerProfile'
110
AUTHENTICATION_BACKENDS = (
111
'django_openid_auth.auth.OpenIDBackend',
112
'django.contrib.auth.backends.ModelBackend',
115
OPENID_CREATE_USERS = True
116
OPENID_UPDATE_DETAILS_FROM_SREG = True
118
LOGIN_URL = '/openid/login/'
119
LOGIN_REDIRECT_URL = '/main/profile'
121
ROOT_URLCONF = 'urls'
81
ROOT_URLCONF = 'bashoneliners.urls'
124
84
# Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
125
85
# Always use forward slashes, even on Windows.
126
86
# Don't forget to use absolute paths, not relative paths.
127
os.path.join(DIRNAME, 'templates'),
130
90
INSTALLED_APPS = (
133
93
'django.contrib.sessions',
134
94
'django.contrib.sites',
135
95
'django.contrib.messages',
136
'django.contrib.staticfiles',
137
96
'django.contrib.admin',
138
97
'django.contrib.admindocs',
139
'django.contrib.markup',
140
'django.contrib.comments',
141
'django_openid_auth',
145
# A sample logging configuration. The only tangible logging
146
# performed by this configuration is to send an email to
147
# the site admins on every HTTP 500 error.
148
# See http://docs.djangoproject.com/en/dev/topics/logging for
149
# more details on how to customize your logging configuration.
153
# logger = logging.getLogger(__name__)
154
# logger.debug('something happened')
157
'disable_existing_loggers': False,
160
'format': '%(levelname)s %(asctime)s %(module)s %(process)d %(thread)d %(message)s',
163
'format': '%(levelname)s %(asctime)s %(module)s %(message)s',
169
'class': 'django.utils.log.AdminEmailHandler'
173
'class': 'logging.FileHandler',
174
'filename': 'debug.log',
175
'formatter': 'simple',
180
'handlers': ['mail_admins'],
185
'handlers': ['file'],
192
### project specific django settings
194
AUTH_PROFILE_MODULE = 'api.UserProfile'
197
### project specific custom settings
201
'consumer_secret': '',
203
'access_token_secret': '',
208
#EMAIL_BACKEND = 'django.core.mail.backends.filebased.EmailBackend'
209
#EMAIL_FILE_PATH = '/tmp/django-emails'
210
#EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
211
EMAIL_FILE_PATH = '/tmp/django-emails.log'
212
EMAIL_BACKEND = 'oneliners.email.CustomFileEmailBackend'
216
GOO_GL_API_URL = 'https://www.googleapis.com/urlshortener/v1/url'
102
''' project specific custom settings '''