-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
27 lines (21 loc) · 941 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Base image
FROM alpine:latest
# This hack is widely applied to avoid python printing issues in docker containers.
# See: https://github.com/Docker-Hub-frolvlad/docker-alpine-python3/pull/13
ENV PYTHONUNBUFFERED=1
RUN echo "**** install dependencies ****" && \
apk add --no-cache bash ca-certificates curl python3 tidyhtml && \
if [ ! -e /usr/bin/python ]; then ln -sf python3 /usr/bin/python ; fi && \
\
echo "**** install pip ****" && \
python3 -m ensurepip && \
rm -r /usr/lib/python*/ensurepip && \
pip3 install --no-cache --upgrade pip setuptools wheel colorama requests validators pytidylib && \
if [ ! -e /usr/bin/pip ]; then ln -s pip3 /usr/bin/pip ; fi
# Copies your code file repository to the filesystem
WORKDIR /src
COPY . /src
# change permission to execute the script
RUN chmod +x /src/entrypoint.sh
# file to execute when the docker container starts up
ENTRYPOINT ["/src/entrypoint.sh"]