Skip to content

Commit 7f73855

Browse files
committed
Switch to Python 3.8
1 parent a79b92a commit 7f73855

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

.travis.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ language: python
44
cache: pip
55

66
python:
7-
- '3.6'
7+
- '3.8'
88

99
env:
1010
- DJANGO_SETTINGS_MODULE=djangofluent.settings.unittest

Dockerfile

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Build environment has gcc and develop header files.
22
# The installed files are copied to the smaller runtime container.
3-
FROM python:3.6-stretch as build-image
3+
FROM python:3.8-stretch as build-image
44
ENV DEBIAN_FRONTEND=noninteractive \
55
PYTHONUNBUFFERED=1 \
66
PIP_NO_CACHE_DIR=off
@@ -12,8 +12,8 @@ ARG PIP_REQUIREMENTS=/app/src/requirements/docker.txt
1212
RUN pip install -r $PIP_REQUIREMENTS
1313

1414
# Remove unneeded files
15-
RUN find /usr/local/lib/python3.6/site-packages/ -name '*.po' -delete && \
16-
find /usr/local/lib/python3.6/site-packages/tinymce/ -regextype posix-egrep -not -regex '.*/langs/(en|nl).*\.js' -wholename '*/langs/*.js' -delete
15+
RUN find /usr/local/lib/python3.8/site-packages/ -name '*.po' -delete && \
16+
find /usr/local/lib/python3.8/site-packages/tinymce/ -regextype posix-egrep -not -regex '.*/langs/(en|nl).*\.js' -wholename '*/langs/*.js' -delete
1717

1818
## Node builder
1919
FROM node:12-stretch as frontend-build
@@ -26,7 +26,7 @@ COPY src/frontend/ /app/src/frontend/
2626
RUN npm run gulp
2727

2828
# Start runtime container
29-
FROM python:3.6-slim-stretch
29+
FROM python:3.8-slim-stretch
3030
ENV DEBIAN_FRONTEND=noninteractive \
3131
PYTHONUNBUFFERED=1 \
3232
PIP_NO_CACHE_DIR=off \
@@ -62,7 +62,7 @@ HEALTHCHECK --interval=5m --timeout=3s CMD curl -f http://localhost:8080/api/hea
6262

6363
# Install dependencies
6464
COPY --from=build-image /usr/local/bin/ /usr/local/bin/
65-
COPY --from=build-image /usr/local/lib/python3.6/site-packages/ /usr/local/lib/python3.6/site-packages/
65+
COPY --from=build-image /usr/local/lib/python3.8/site-packages/ /usr/local/lib/python3.8/site-packages/
6666
COPY --from=frontend-build /app/src/frontend/static /app/src/frontend/static
6767

6868
# Insert application code.

deployment/docker/uwsgi.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ add-header = Connection: Keep-Alive
5959
# Static file serving with caching headers and gzip
6060
static-map = /static=/app/web/static
6161
static-map = /media=/app/web/media
62-
static-safe = /usr/local/lib/python3.6/site-packages/
62+
static-safe = /usr/local/lib/python3.8/site-packages/
6363
static-safe = /app/src/frontend/static/
6464
static-gzip-dir = /app/web/static/
6565
route-uri = ^/static/ addheader:Vary: Accept-Encoding

0 commit comments

Comments
 (0)