aboutsummaryrefslogtreecommitdiffstats
path: root/docker
diff options
context:
space:
mode:
authorGravatar Johannes Christ <[email protected]>2018-09-19 22:14:24 +0200
committerGravatar Johannes Christ <[email protected]>2018-09-19 22:49:15 +0200
commitdec23d058eb9fdfeee33e9a4a61e3e65ccb0b490 (patch)
treeb67612bd0eccfc301c376443fd65d468385cb7fe /docker
parentMerge branch 'django+mdlint' into django (diff)
Add dockerfile lints.
Diffstat (limited to 'docker')
-rw-r--r--docker/app/alpine/3.6/Dockerfile13
-rw-r--r--docker/app/alpine/3.7/Dockerfile13
-rw-r--r--docker/app/stretch/3.6/Dockerfile11
-rw-r--r--docker/app/stretch/3.7/Dockerfile13
4 files changed, 29 insertions, 21 deletions
diff --git a/docker/app/alpine/3.6/Dockerfile b/docker/app/alpine/3.6/Dockerfile
index c460815b..b610d410 100644
--- a/docker/app/alpine/3.6/Dockerfile
+++ b/docker/app/alpine/3.6/Dockerfile
@@ -2,18 +2,17 @@ FROM python:3.6-alpine
ARG EXTRAS=deploy
-# Build-time dependencies: To be removed later.
-RUN apk add --virtual build \
+RUN apk add --no-cache --virtual build \
gcc \
- musl-dev
-
-# Used by the healthcheck and shared library used by psycopg2.
-RUN apk add --no-cache curl postgresql-dev
+ musl-dev \
+ && \
+ apk add --no-cache \
+ curl \
+ postgresql-dev
WORKDIR /app
COPY setup.py /app/setup.py
RUN python3 -m pip install .[$EXTRAS]
-# Remove dependencies used for building psycopg2.
RUN apk del --purge build
COPY . .
diff --git a/docker/app/alpine/3.7/Dockerfile b/docker/app/alpine/3.7/Dockerfile
index 83dbdb96..ccc6d5d2 100644
--- a/docker/app/alpine/3.7/Dockerfile
+++ b/docker/app/alpine/3.7/Dockerfile
@@ -2,18 +2,17 @@ FROM python:3.7-alpine
ARG EXTRAS=deploy
-# Build-time dependencies: To be removed later.
-RUN apk add --virtual build \
+RUN apk add --no-cache --virtual build \
gcc \
- musl-dev
-
-# Used by the healthcheck and shared library used by psycopg2.
-RUN apk add --no-cache curl postgresql-dev
+ musl-dev \
+ && \
+ apk add --no-cache \
+ curl \
+ postgresql-dev
WORKDIR /app
COPY setup.py /app/setup.py
RUN python3 -m pip install .[$EXTRAS]
-# Remove dependencies used for building psycopg2.
RUN apk del --purge build
COPY . .
diff --git a/docker/app/stretch/3.6/Dockerfile b/docker/app/stretch/3.6/Dockerfile
index a52317da..0e840899 100644
--- a/docker/app/stretch/3.6/Dockerfile
+++ b/docker/app/stretch/3.6/Dockerfile
@@ -2,11 +2,16 @@ FROM python:3.6-stretch
ARG EXTRAS=deploy
-RUN apt-get update -y
-RUN apt-get install -y \
+RUN apt-get update -y \
+ && \
+ apt-get install --no-install-recommends -y \
gcc \
libc-dev \
- libpq-dev
+ libpq-dev \
+ && \
+ apt-get clean \
+ && \
+ rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY setup.py /app/setup.py
diff --git a/docker/app/stretch/3.7/Dockerfile b/docker/app/stretch/3.7/Dockerfile
index 1e832e32..0d4a9f3e 100644
--- a/docker/app/stretch/3.7/Dockerfile
+++ b/docker/app/stretch/3.7/Dockerfile
@@ -2,11 +2,16 @@ FROM python:3.7-stretch
ARG EXTRAS=deploy
-RUN apt-get update -y
-RUN apt-get install -y \
+RUN apt-get update -y \
+ && \
+ apt-get install --no-install-recommends -y \
gcc \
libc-dev \
- libpq-dev
+ libpq-dev \
+ && \
+ apt-get clean \
+ && \
+ rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY setup.py /app/setup.py
@@ -18,4 +23,4 @@ RUN apt-get purge -y \
libc-dev \
libpq-dev
-CMD ["gunicorn", "--workers", "4", "--bind", "0.0.0.0:4000", "pysite.wsgi:applicati
+CMD ["gunicorn", "--workers", "4", "--bind", "0.0.0.0:4000", "pysite.wsgi:application"]