This commit is contained in:
parent
78dec73b6c
commit
31f3e52df8
10
Dockerfile
10
Dockerfile
@ -1,6 +1,7 @@
|
|||||||
FROM python:alpine AS build
|
FROM python:alpine AS build
|
||||||
RUN apk add --no-cache gcc make musl-dev linux-headers git \
|
RUN apk add --no-cache gcc make musl-dev linux-headers git \
|
||||||
&& pip3 wheel --wheel-dir=/wheels \
|
&& pip3 wheel --wheel-dir=/wheels \
|
||||||
|
aiofile \
|
||||||
flask \
|
flask \
|
||||||
git+https://github.com/Assarius/sanic-prometheus@Sanic_22 \
|
git+https://github.com/Assarius/sanic-prometheus@Sanic_22 \
|
||||||
kubernetes \
|
kubernetes \
|
||||||
@ -13,6 +14,15 @@ RUN apk add --no-cache gcc make musl-dev linux-headers git \
|
|||||||
sanic-ext \
|
sanic-ext \
|
||||||
sanic-wtf \
|
sanic-wtf \
|
||||||
ecs-logging
|
ecs-logging
|
||||||
|
|
||||||
|
# Work around buggy setup.py in caio
|
||||||
|
RUN git clone https://github.com/mosquito/caio/ \
|
||||||
|
&& cd caio \
|
||||||
|
&& python3 setup.py bdist_wheel \
|
||||||
|
&& rm /wheels/*caio*.whl \
|
||||||
|
&& cp dist/*.whl /wheels/
|
||||||
|
|
||||||
|
# Generate image without build dependencies
|
||||||
FROM python:alpine
|
FROM python:alpine
|
||||||
COPY --from=build /wheels /wheels
|
COPY --from=build /wheels /wheels
|
||||||
RUN pip3 install --no-index /wheels/*.whl && rm -Rfv /wheels
|
RUN pip3 install --no-index /wheels/*.whl && rm -Rfv /wheels
|
||||||
|
Loading…
Reference in New Issue
Block a user