-
Notifications
You must be signed in to change notification settings - Fork 41
Expand file tree
/
Copy pathdevelopment.py
More file actions
46 lines (38 loc) · 1.34 KB
/
development.py
File metadata and controls
46 lines (38 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# development.py, settings file
# see https://djangostars.com/blog/configuring-django-settings-best-practices/
# Two Scoops of Django, p. 47: "For the singular case of Django setting modules we want to override all the namespace"
# Therefore the below "import *" is correct
from .base import *
DEBUG = True
WAGTAILADMIN_BASE_URL = 'http://localhost:8000/'
ALLOWED_HOSTS = ['localhost', '*']
INTERNAL_IPS = ['127.0.0.1', '0.0.0.0', 'localhost']
# The dummy cache does not cache any values. We use this in development
# so that the website always updates after code changes.
CACHES = {
"default": {
'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
},
"renditions": {
'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
}
}
TEMPLATES += [
{
'NAME': 'ubyssey',
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [
BASE_DIR('ubyssey/templates/')
],
'OPTIONS': {
'context_processors': [
'django.template.context_processors.request',
],
},
}
]
GCS_CREDENTIALS_FILE = '../gcs-local.json'
MEDIA_ROOT = os.path.join(BASE_DIR, 'media')
# Use in-memory file handler on Google App Engine
FILE_UPLOAD_HANDLERS = ['django.core.files.uploadhandler.MemoryFileUploadHandler',]
FILE_UPLOAD_MAX_MEMORY_SIZE = 25621440