2021-02-01 01:46:48 +08:00
|
|
|
FROM alpine:3.13
|
|
|
|
|
2021-02-01 02:04:55 +08:00
|
|
|
ENV PYTHONUNBUFFERED=1
|
|
|
|
|
2021-02-01 01:46:48 +08:00
|
|
|
RUN apk update && \
|
|
|
|
apk add python3 curl && \
|
|
|
|
curl --silent --show-error --retry 5 https://bootstrap.pypa.io/get-pip.py | python3 && \
|
|
|
|
apk del curl
|
|
|
|
|
|
|
|
COPY requirements.txt /tmp/requirements.txt
|
|
|
|
|
|
|
|
RUN pip3 install -r /tmp/requirements.txt && \
|
|
|
|
rm -f /tmp/requirements.txt
|
|
|
|
|
2021-11-07 04:52:23 +08:00
|
|
|
COPY src /opt/app
|
|
|
|
|
|
|
|
WORKDIR /opt/app
|
2021-02-01 01:46:48 +08:00
|
|
|
|
2021-02-01 02:02:39 +08:00
|
|
|
ENTRYPOINT ["python3"]
|
2021-11-07 04:52:23 +08:00
|
|
|
CMD ["app.py"]
|
2021-02-01 02:02:39 +08:00
|
|
|
|