|
| 1 | +""" |
| 2 | +Django settings for note_app project. |
| 3 | +
|
| 4 | +For more information on this file, see |
| 5 | +https://docs.djangoproject.com/en/1.7/topics/settings/ |
| 6 | +
|
| 7 | +For the full list of settings and their values, see |
| 8 | +https://docs.djangoproject.com/en/1.7/ref/settings/ |
| 9 | +""" |
| 10 | + |
| 11 | +# Build paths inside the project like this: os.path.join(BASE_DIR, ...) |
| 12 | +import os |
| 13 | +BASE_DIR = os.path.dirname(os.path.dirname(__file__)) |
| 14 | + |
| 15 | + |
| 16 | +# Quick-start development settings - unsuitable for production |
| 17 | +# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/ |
| 18 | + |
| 19 | +# SECURITY WARNING: keep the secret key used in production secret! |
| 20 | +SECRET_KEY = 'jk2j%o(&zjh38&6mo&fo*8lz%ad0*mxdsfi($jmn*1694@8zk9' |
| 21 | + |
| 22 | +# SECURITY WARNING: don't run with debug turned on in production! |
| 23 | +DEBUG = True |
| 24 | + |
| 25 | +TEMPLATE_DEBUG = True |
| 26 | + |
| 27 | +ALLOWED_HOSTS = [] |
| 28 | + |
| 29 | + |
| 30 | +# Application definition |
| 31 | + |
| 32 | +INSTALLED_APPS = ( |
| 33 | + 'django.contrib.admin', |
| 34 | + 'django.contrib.auth', |
| 35 | + 'django.contrib.contenttypes', |
| 36 | + 'django.contrib.sessions', |
| 37 | + 'django.contrib.messages', |
| 38 | + 'django.contrib.staticfiles', |
| 39 | + 'notes', |
| 40 | +) |
| 41 | + |
| 42 | +MIDDLEWARE_CLASSES = ( |
| 43 | + 'django.contrib.sessions.middleware.SessionMiddleware', |
| 44 | + 'django.middleware.common.CommonMiddleware', |
| 45 | + 'django.middleware.csrf.CsrfViewMiddleware', |
| 46 | + 'django.contrib.auth.middleware.AuthenticationMiddleware', |
| 47 | + 'django.contrib.auth.middleware.SessionAuthenticationMiddleware', |
| 48 | + 'django.contrib.messages.middleware.MessageMiddleware', |
| 49 | + 'django.middleware.clickjacking.XFrameOptionsMiddleware', |
| 50 | +) |
| 51 | + |
| 52 | +ROOT_URLCONF = 'note_app.urls' |
| 53 | + |
| 54 | +WSGI_APPLICATION = 'note_app.wsgi.application' |
| 55 | + |
| 56 | + |
| 57 | +# Database |
| 58 | +# https://docs.djangoproject.com/en/1.7/ref/settings/#databases |
| 59 | + |
| 60 | +DATABASES = { |
| 61 | + 'default': { |
| 62 | + 'ENGINE': 'django.db.backends.sqlite3', |
| 63 | + 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'), |
| 64 | + } |
| 65 | +} |
| 66 | + |
| 67 | +# Internationalization |
| 68 | +# https://docs.djangoproject.com/en/1.7/topics/i18n/ |
| 69 | + |
| 70 | +LANGUAGE_CODE = 'en-us' |
| 71 | + |
| 72 | +TIME_ZONE = 'UTC' |
| 73 | + |
| 74 | +USE_I18N = True |
| 75 | + |
| 76 | +USE_L10N = True |
| 77 | + |
| 78 | +USE_TZ = True |
| 79 | + |
| 80 | + |
| 81 | +# Static files (CSS, JavaScript, Images) |
| 82 | +# https://docs.djangoproject.com/en/1.7/howto/static-files/ |
| 83 | + |
| 84 | +STATIC_URL = '/static/' |
| 85 | + |
| 86 | +TEMPLATE_DIRS = (os.path.join(os.path.dirname(BASE_DIR), 'note_app', 'static', 'templates'),) |
| 87 | + |
0 commit comments