diff options
author | 2019-04-05 13:46:50 +0100 | |
---|---|---|
committer | 2019-04-05 13:46:50 +0100 | |
commit | 0936db6072db68d9f724c49c3e7252680f6e8867 (patch) | |
tree | abb566abec75b4a2fe36f4d58c753b34d11231cb | |
parent | [#158 #160] Add crispy-bulma and simple-bulma (diff) |
[#158 #160] Automatically run collectstatic in containers/setup script
-rw-r--r-- | docker/app/alpine/3.6/Dockerfile | 2 | ||||
-rw-r--r-- | docker/app/alpine/3.7/Dockerfile | 2 | ||||
-rwxr-xr-x | docker/app/migrate_and_serve.sh | 2 | ||||
-rw-r--r-- | docker/app/stretch/3.6/Dockerfile | 2 | ||||
-rw-r--r-- | docker/app/stretch/3.7/Dockerfile | 2 |
5 files changed, 10 insertions, 0 deletions
diff --git a/docker/app/alpine/3.6/Dockerfile b/docker/app/alpine/3.6/Dockerfile index 1abcd537..c40b6593 100644 --- a/docker/app/alpine/3.6/Dockerfile +++ b/docker/app/alpine/3.6/Dockerfile @@ -28,4 +28,6 @@ RUN python3 -m pip install pipenv \ COPY . . +RUN python3 manage.py collectstatic --no-input --clear + CMD ["uwsgi", "--ini", "docker/app/uwsgi.ini"] diff --git a/docker/app/alpine/3.7/Dockerfile b/docker/app/alpine/3.7/Dockerfile index 955c01be..9dfbfe09 100644 --- a/docker/app/alpine/3.7/Dockerfile +++ b/docker/app/alpine/3.7/Dockerfile @@ -27,4 +27,6 @@ RUN python3 -m pip install pipenv \ COPY . . +RUN python3 manage.py collectstatic --no-input --clear + CMD ["uwsgi", "--ini", "docker/app/uwsgi.ini"] diff --git a/docker/app/migrate_and_serve.sh b/docker/app/migrate_and_serve.sh index 032504e2..50df2cbb 100755 --- a/docker/app/migrate_and_serve.sh +++ b/docker/app/migrate_and_serve.sh @@ -9,5 +9,7 @@ echo [i] Applying migrations. python manage.py migrate --verbosity 0 +echo [i] Collecting static files. +python manage.py collectstatic --no-input --clear --verbosity 0 echo [i] Starting server. python manage.py runserver 0.0.0.0:8000 diff --git a/docker/app/stretch/3.6/Dockerfile b/docker/app/stretch/3.6/Dockerfile index 3ce69018..5f97a510 100644 --- a/docker/app/stretch/3.6/Dockerfile +++ b/docker/app/stretch/3.6/Dockerfile @@ -29,6 +29,8 @@ RUN python3 -m pip install pipenv \ COPY . . +RUN python3 manage.py collectstatic --no-input --clear + RUN apt-get purge -y \ gcc \ libc-dev \ diff --git a/docker/app/stretch/3.7/Dockerfile b/docker/app/stretch/3.7/Dockerfile index c2f10cea..a1538ddd 100644 --- a/docker/app/stretch/3.7/Dockerfile +++ b/docker/app/stretch/3.7/Dockerfile @@ -29,6 +29,8 @@ RUN python3 -m pip install pipenv \ COPY . . +RUN python3 manage.py collectstatic --no-input --clear + RUN apt-get purge -y \ gcc \ libc-dev \ |