Skip to content

Commit 81c7ee6

Browse files
committed
collectstatic
1 parent ac39f0a commit 81c7ee6

File tree

2 files changed

+26
-0
lines changed

2 files changed

+26
-0
lines changed

Dockerfile.cabotage

+1
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ COPY prod-requirements.txt /code/
88
COPY requirements.txt /code/
99
RUN pip install -r requirements.txt
1010
COPY . /code/
11+
RUN DJANGO_SETTINGS_MODULE=pydotorg.settings.static python manage.py collectstatic --noinput

pydotorg/settings/static.py

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import os
2+
3+
import dj_database_url
4+
import raven
5+
from decouple import Csv
6+
7+
from .base import *
8+
9+
DEBUG = TEMPLATE_DEBUG = False
10+
11+
HAYSTACK_CONNECTIONS = {
12+
'default': {
13+
'ENGINE': 'haystack.backends.elasticsearch5_backend.Elasticsearch5SearchEngine',
14+
'URL': 'http://127.0.0.1:9200',
15+
'INDEX_NAME': 'haystack-null',
16+
},
17+
}
18+
19+
MIDDLEWARE = [
20+
'whitenoise.middleware.WhiteNoiseMiddleware',
21+
] + MIDDLEWARE
22+
23+
MEDIAFILES_LOCATION = 'media'
24+
DEFAULT_FILE_STORAGE = 'custom_storages.storages.MediaStorage'
25+
STATICFILES_STORAGE = 'custom_storages.storages.PipelineManifestStorage'

0 commit comments

Comments
 (0)