certbot/Dockerfile

36 lines
1.1 KiB
Docker
Raw Permalink Normal View History

FROM python:2-alpine3.9
ENTRYPOINT [ "certbot" ]
2017-01-12 07:01:29 -05:00
EXPOSE 80 443
VOLUME /etc/letsencrypt /var/lib/letsencrypt
2016-04-14 13:20:23 -04:00
WORKDIR /opt/certbot
COPY CHANGELOG.md README.rst setup.py src/
# Generate constraints file to pin dependency versions
COPY letsencrypt-auto-source/pieces/dependency-requirements.txt .
COPY tools /opt/certbot/tools
RUN sh -c 'cat dependency-requirements.txt | /opt/certbot/tools/strip_hashes.py > unhashed_requirements.txt'
RUN sh -c 'cat tools/dev_constraints.txt unhashed_requirements.txt | /opt/certbot/tools/merge_requirements.py > docker_constraints.txt'
COPY acme src/acme
COPY certbot src/certbot
2017-01-12 07:01:29 -05:00
RUN apk add --no-cache --virtual .certbot-deps \
libffi \
libssl1.1 \
openssl \
2017-01-12 07:01:29 -05:00
ca-certificates \
binutils
RUN apk add --no-cache --virtual .build-deps \
gcc \
linux-headers \
openssl-dev \
musl-dev \
libffi-dev \
&& pip install -r /opt/certbot/dependency-requirements.txt \
&& pip install --no-cache-dir --no-deps \
2017-01-12 07:01:29 -05:00
--editable /opt/certbot/src/acme \
--editable /opt/certbot/src \
&& apk del .build-deps