2 Django settings for plgng project.
4 For more information on this file, see
5 https://docs.djangoproject.com/en/1.7/topics/settings/
7 For the full list of settings and their values, see
8 https://docs.djangoproject.com/en/1.7/ref/settings/
11 # Build paths inside the project like this: os.path.join(BASE_DIR, ...)
14 import django.conf.global_settings as defaults
17 BASE_DIR = os.path.dirname(os.path.dirname(__file__))
20 # Quick-start development settings - unsuitable for production
21 # See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/
23 # SECURITY WARNING: keep the secret key used in production secret!
24 SECRET_KEY = 'x%_rlnhibsxum1m5o_c5ac@p0nw+1r0&#k!v3+52)s(d=2$5y&'
26 # SECURITY WARNING: don't run with debug turned on in production!
34 # Application definition
38 'django.contrib.admin',
39 'django.contrib.auth',
40 'django.contrib.contenttypes',
41 'django.contrib.sessions',
42 'django.contrib.messages',
43 'django.contrib.staticfiles',
44 'django.contrib.webdesign',
49 MIDDLEWARE_CLASSES = (
50 'django.contrib.sessions.middleware.SessionMiddleware',
51 'django.middleware.common.CommonMiddleware',
52 'django.middleware.csrf.CsrfViewMiddleware',
53 'django.contrib.auth.middleware.AuthenticationMiddleware',
54 'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
55 'django.contrib.messages.middleware.MessageMiddleware',
56 'django.middleware.clickjacking.XFrameOptionsMiddleware',
59 TEMPLATE_CONTEXT_PROCESSORS = defaults.TEMPLATE_CONTEXT_PROCESSORS + (
60 'django.core.context_processors.request',
63 ROOT_URLCONF = 'plgng.urls'
65 WSGI_APPLICATION = 'plgng.wsgi.application'
69 # https://docs.djangoproject.com/en/1.7/ref/settings/#databases
73 'ENGINE': 'django.db.backends.sqlite3',
74 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
78 # Internationalization
79 # https://docs.djangoproject.com/en/1.7/topics/i18n/
83 TIME_ZONE = 'Europe/Warsaw'
92 # Static files (CSS, JavaScript, Images)
93 # https://docs.djangoproject.com/en/1.7/howto/static-files/
95 STATIC_URL = '/static/'
100 AUTHENTICATION_BACKENDS = (
101 'django_openid_auth.auth.OpenIDBackend',
102 'django.contrib.auth.backends.ModelBackend',
105 LOGIN_URL = 'openid-login'
106 LOGIN_REDIRECT_URL = '/jobs/'
108 # If set, always use this as the identity URL rather than asking the
109 # user. This only makes sense if it is a server URL.
110 OPENID_SSO_SERVER_URL = 'https://openid.plgrid.pl/gateway'
112 # Should users be created when new OpenIDs are used to log in?
113 OPENID_CREATE_USERS = True
115 # Update user details from OpenID each time they log in
116 OPENID_UPDATE_DETAILS_FROM_SREG = True
118 # Login will fail if no 'nickname' (username), or if the nickname
119 # conflicts with an existing user with a different openid identity url
120 OPENID_STRICT_USERNAMES = True
123 SESSION_SERIALIZER = 'django.contrib.sessions.serializers.PickleSerializer'