~chipaca/unity-lens-video/custom-user-agent

« back to all changes in this revision

Viewing changes to settings.py.sample

  • Committer: Janos Gyerik
  • Date: 2011-08-08 20:19:00 UTC
  • Revision ID: janos@axiom-20110808201900-rpq8pghds6gf8vnl
top 50 link now works

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
import os
4
4
DIRNAME = os.path.abspath(os.path.dirname(__file__))
5
5
 
6
 
DEBUG = False
7
6
DEBUG = True
8
7
TEMPLATE_DEBUG = DEBUG
9
8
 
10
9
ADMINS = (
11
 
    ('Bash One-Liners DEV', 'info@bashoneliners.com'),
 
10
    # ('Your Name', 'your_email@domain.com'),
12
11
)
13
12
 
14
13
MANAGERS = ADMINS
15
14
 
16
15
DATABASES = {
17
16
    'default': {
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
48
47
USE_L10N = True
49
48
 
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/')
53
52
 
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/'
 
57
 
 
58
# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
55
59
# trailing slash.
56
 
# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
57
 
MEDIA_URL = ''
58
 
 
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/"
63
 
STATIC_ROOT = ''
64
 
 
65
 
# URL prefix for static files.
66
 
# Example: "http://media.lawrence.com/static/"
67
 
STATIC_URL = '/media/'
68
 
 
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/'
73
 
 
74
 
# Additional locations of static files
75
 
STATICFILES_DIRS = (
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'),
80
 
)
81
 
 
82
 
# List of finder classes that know how to find static files in
83
 
# various locations.
84
 
STATICFILES_FINDERS = (
85
 
    'django.contrib.staticfiles.finders.FileSystemFinder',
86
 
    'django.contrib.staticfiles.finders.AppDirectoriesFinder',
87
 
#    'django.contrib.staticfiles.finders.DefaultStorageFinder',
88
 
)
 
60
# Examples: "http://foo.com/media/", "/media/".
 
61
ADMIN_MEDIA_PREFIX = '/admin_media/'
89
62
 
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',
106
79
)
107
80
 
108
 
AUTH_PROFILE_MODULE = 'oneliners.models.HackerProfile'
109
 
 
110
 
AUTHENTICATION_BACKENDS = (
111
 
        'django_openid_auth.auth.OpenIDBackend',
112
 
        'django.contrib.auth.backends.ModelBackend',
113
 
        )
114
 
 
115
 
OPENID_CREATE_USERS = True
116
 
OPENID_UPDATE_DETAILS_FROM_SREG = True
117
 
 
118
 
LOGIN_URL = '/openid/login/'
119
 
LOGIN_REDIRECT_URL = '/main/profile'
120
 
 
121
 
ROOT_URLCONF = 'urls'
 
81
ROOT_URLCONF = 'bashoneliners.urls'
122
82
 
123
83
TEMPLATE_DIRS = (
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'),
 
87
    'templates',
128
88
)
129
89
 
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',
142
 
    'oneliners',
 
98
    'bashoneliners.main',
143
99
)
144
100
 
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.
150
 
#
151
 
# Example usage:
152
 
# import logging
153
 
# logger = logging.getLogger(__name__)
154
 
# logger.debug('something happened')
155
 
LOGGING = {
156
 
    'version': 1,
157
 
    'disable_existing_loggers': False,
158
 
    'formatters': {
159
 
        'verbose': {
160
 
            'format': '%(levelname)s %(asctime)s %(module)s %(process)d %(thread)d %(message)s',
161
 
        },
162
 
        'simple': {
163
 
            'format': '%(levelname)s %(asctime)s %(module)s %(message)s',
164
 
        },
165
 
    },
166
 
    'handlers': {
167
 
        'mail_admins': {
168
 
            'level': 'ERROR',
169
 
            'class': 'django.utils.log.AdminEmailHandler'
170
 
        },
171
 
        'file': {
172
 
            'level': 'DEBUG',
173
 
            'class': 'logging.FileHandler',
174
 
            'filename': 'debug.log',
175
 
            'formatter': 'simple',
176
 
        },
177
 
    },
178
 
    'loggers': {
179
 
        'django.request': {
180
 
            'handlers': ['mail_admins'],
181
 
            'level': 'ERROR',
182
 
            'propagate': True,
183
 
        },
184
 
        'oneliners': {
185
 
            'handlers': ['file'],
186
 
            'level': 'DEBUG',
187
 
        },
188
 
    }
189
 
}
190
 
 
191
 
 
192
 
### project specific django settings
193
 
 
194
 
AUTH_PROFILE_MODULE = 'api.UserProfile'
195
 
 
196
 
 
197
 
### project specific custom settings
198
 
 
199
 
TWITTER = {
200
 
        'consumer_key': '',
201
 
        'consumer_secret': '',
202
 
        'access_token': '',
203
 
        'access_token_secret': '',
204
 
        }
205
 
 
206
 
### emails
207
 
#
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'
213
 
 
214
 
### url shortening
215
 
#
216
 
GOO_GL_API_URL = 'https://www.googleapis.com/urlshortener/v1/url'
217
 
GOO_GL_API_KEY = ''
 
101
 
 
102
''' project specific custom settings '''
 
103
 
218
104
 
219
105
 
220
106
# eof