~ris/loco-team-portal/fix-552762

« back to all changes in this revision

Viewing changes to loco_directory/settings.py.sample

  • Committer: Daniel Holbach
  • Date: 2009-12-21 11:03:49 UTC
  • Revision ID: daniel.holbach@canonical.com-20091221110349-bo2zmme5i2e4egif
start at revision 1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Django settings for loco_directory project.
 
2
 
 
3
import os
 
4
 
 
5
PROJECT_PATH = os.path.dirname(os.path.abspath(__file__))
 
6
 
 
7
DEBUG = True
 
8
TEMPLATE_DEBUG = DEBUG
 
9
STATIC_SERVE = True
 
10
 
 
11
ADMINS = (
 
12
    ('somebody', 'somebody@example.com'),
 
13
)
 
14
 
 
15
MANAGERS = ADMINS
 
16
LP_PROJECT_NAME = 'loco-directory'
 
17
 
 
18
DATABASE_ENGINE = 'postgresql_psycopg2'
 
19
DATABASE_NAME = 'loco_directory'
 
20
DATABASE_USER = ''
 
21
DATABASE_PASSWORD = ''
 
22
DATABASE_HOST = '127.0.0.1'
 
23
DATABASE_PORT = '5432'
 
24
 
 
25
# Local time zone for this installation. Choices can be found here:
 
26
# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
 
27
# although not all choices may be available on all operating systems.
 
28
# If running in a Windows environment this must be set to the same as your
 
29
# system time zone.
 
30
TIME_ZONE = 'UTC'
 
31
 
 
32
# Language code for this installation. All choices can be found here:
 
33
# http://www.i18nguy.com/unicode/language-identifiers.html
 
34
LANGUAGE_CODE = 'en-us'
 
35
 
 
36
SITE_ID = 1
 
37
 
 
38
# If you set this to False, Django will make some optimizations so as not
 
39
# to load the internationalization machinery.
 
40
USE_I18N = True
 
41
 
 
42
# Absolute path to the directory that holds media.
 
43
# Example: "/home/media/media.lawrence.com/"
 
44
MEDIA_ROOT = os.path.join(PROJECT_PATH, 'media')
 
45
 
 
46
# URL that handles the media served from MEDIA_ROOT. Make sure to use a
 
47
# trailing slash if there is a path component (optional in other cases).
 
48
# Examples: "http://media.lawrence.com", "http://example.com/media/"
 
49
MEDIA_URL = '/media/'
 
50
 
 
51
# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
 
52
# trailing slash.
 
53
# Examples: "http://foo.com/media/", "/media/".
 
54
ADMIN_MEDIA_PREFIX = '/media/admin/'
 
55
 
 
56
# Make this unique, and don't share it with anybody.
 
57
SECRET_KEY = ''
 
58
 
 
59
# List of callables that know how to import templates from various sources.
 
60
TEMPLATE_LOADERS = (
 
61
    'django.template.loaders.filesystem.load_template_source',
 
62
    'django.template.loaders.app_directories.load_template_source',
 
63
)
 
64
 
 
65
MIDDLEWARE_CLASSES = (
 
66
    'django.middleware.common.CommonMiddleware',
 
67
    'django.middleware.locale.LocaleMiddleware',
 
68
    'django.contrib.sessions.middleware.SessionMiddleware',
 
69
    'django.contrib.auth.middleware.AuthenticationMiddleware',
 
70
)
 
71
 
 
72
ROOT_URLCONF = 'loco_directory.urls'
 
73
 
 
74
TEMPLATE_DIRS = (
 
75
    # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
 
76
    # Always use forward slashes, even on Windows.
 
77
    # Don't forget to use absolute paths, not relative paths.
 
78
    os.path.join(PROJECT_PATH, 'templates'),
 
79
)
 
80
 
 
81
INSTALLED_APPS = (
 
82
    'django.contrib.auth',
 
83
    'django.contrib.contenttypes',
 
84
    'django.contrib.sessions',
 
85
    'django.contrib.admin',
 
86
    'common',
 
87
    'teams',
 
88
    'django_openid_auth',
 
89
)
 
90
 
 
91
AUTHENTICATION_BACKENDS = (
 
92
    'django_openid_auth.auth.OpenIDBackend',
 
93
    'django.contrib.auth.backends.ModelBackend',
 
94
)
 
95
 
 
96
# Should users be created when new OpenIDs are used to log in?
 
97
OPENID_CREATE_USERS = True
 
98
 
 
99
# Can we reuse existing users?
 
100
OPENID_REUSE_USERS = True
 
101
 
 
102
# When logging in again, should we overwrite user details based on
 
103
# data received via Simple Registration?
 
104
OPENID_UPDATE_DETAILS_FROM_SREG = True
 
105
 
 
106
# If set, always use this as the identity URL rather than asking the
 
107
# user.  This only makes sense if it is a server URL.
 
108
OPENID_SSO_SERVER_URL = 'https://login.launchpad.net/'
 
109
 
 
110
# Tell django.contrib.auth to use the OpenID signin URLs.
 
111
LOGIN_URL = '/openid/login'
 
112
LOGIN_REDIRECT_URL = '/'
 
113