Skip to content

Commit 6f4f2eb

Browse files
committed
update getting started settings for 1.8
1 parent 2e07fa5 commit 6f4f2eb

1 file changed

Lines changed: 25 additions & 7 deletions

File tree

gettingstarted/settings.py

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
"""
2-
Django settings for gettingstarted project.
2+
Django settings for gettingstarted project, on Heroku. Fore more info, see:
3+
https://github.com/heroku/heroku-django-template
34
45
For more information on this file, see
5-
https://docs.djangoproject.com/en/1.6/topics/settings/
6+
https://docs.djangoproject.com/en/1.8/topics/settings/
67
78
For the full list of settings and their values, see
8-
https://docs.djangoproject.com/en/1.6/ref/settings/
9+
https://docs.djangoproject.com/en/1.8/ref/settings/
910
"""
1011

1112
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
@@ -18,7 +19,7 @@
1819

1920

2021
# Quick-start development settings - unsuitable for production
21-
# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/
22+
# See https://docs.djangoproject.com/en/1.8/howto/deployment/checklist/
2223

2324
# SECURITY WARNING: keep the secret key used in production secret!
2425
SECRET_KEY = 'i+acxn5(akgsn!sr4^qgf(^m&*@+g1@u^t@=8s@axc41ml*f=s'
@@ -49,15 +50,32 @@
4950
'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
5051
'django.contrib.messages.middleware.MessageMiddleware',
5152
'django.middleware.clickjacking.XFrameOptionsMiddleware',
53+
'django.middleware.security.SecurityMiddleware',
5254
)
5355

5456
ROOT_URLCONF = 'gettingstarted.urls'
5557

58+
TEMPLATES = [
59+
{
60+
'BACKEND': 'django.template.backends.django.DjangoTemplates',
61+
'DIRS': [],
62+
'APP_DIRS': True,
63+
'OPTIONS': {
64+
'context_processors': [
65+
'django.template.context_processors.debug',
66+
'django.template.context_processors.request',
67+
'django.contrib.auth.context_processors.auth',
68+
'django.contrib.messages.context_processors.messages',
69+
],
70+
},
71+
},
72+
]
73+
5674
WSGI_APPLICATION = 'gettingstarted.wsgi.application'
5775

5876

5977
# Database
60-
# https://docs.djangoproject.com/en/1.7/ref/settings/#databases
78+
# https://docs.djangoproject.com/en/1.8/ref/settings/#databases
6179

6280
DATABASES = {
6381
'default': {
@@ -67,7 +85,7 @@
6785
}
6886

6987
# Internationalization
70-
# https://docs.djangoproject.com/en/1.7/topics/i18n/
88+
# https://docs.djangoproject.com/en/1.8/topics/i18n/
7189

7290
LANGUAGE_CODE = 'en-us'
7391
TIME_ZONE = 'UTC'
@@ -89,7 +107,7 @@
89107
ALLOWED_HOSTS = ['*']
90108

91109
# Static files (CSS, JavaScript, Images)
92-
# https://docs.djangoproject.com/en/1.7/howto/static-files/
110+
# https://docs.djangoproject.com/en/1.8/howto/static-files/
93111

94112
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
95113
STATIC_ROOT = 'staticfiles'

0 commit comments

Comments
 (0)