From 971ed2542ab06cd618f60926e61d21b1e130a541 Mon Sep 17 00:00:00 2001 From: humanoid2050 Date: Sat, 4 Mar 2023 11:15:54 -0500 Subject: [PATCH] Move to multistage Dockerfile --- tools/docker/core/Dockerfile | 48 ---------------------------------- tools/docker/plugin/Dockerfile | 14 ---------- 2 files changed, 62 deletions(-) delete mode 100644 tools/docker/core/Dockerfile delete mode 100644 tools/docker/plugin/Dockerfile diff --git a/tools/docker/core/Dockerfile b/tools/docker/core/Dockerfile deleted file mode 100644 index 911e7796a..000000000 --- a/tools/docker/core/Dockerfile +++ /dev/null @@ -1,48 +0,0 @@ -# Docker Arch (amd64, arm32v6, ...) -ARG TARGET_ARCH -FROM ${TARGET_ARCH}/python:3.10-alpine3.16 - -# Qemu Arch (x86_64, arm, ...) -ARG QEMU_ARCH -ENV QEMU_ARCH=${QEMU_ARCH} -COPY qemu-${QEMU_ARCH}-static /usr/bin/ - -ENTRYPOINT [ "certbot" ] -EXPOSE 80 443 -VOLUME /etc/letsencrypt /var/lib/letsencrypt -WORKDIR /opt/certbot - -# Copy certbot code -COPY CHANGELOG.md README.rst src/ -COPY tools tools -COPY acme src/acme -COPY certbot src/certbot - -# Install certbot runtime dependencies -RUN apk add --no-cache --virtual .certbot-deps \ - libffi \ - libssl1.1 \ - openssl \ - ca-certificates \ - binutils - -# We set this environment variable and install git while building to try and -# increase the stability of fetching the rust crates needed to build the -# cryptography library -ARG CARGO_NET_GIT_FETCH_WITH_CLI=true -# Install certbot from sources -RUN apk add --no-cache --virtual .build-deps \ - gcc \ - linux-headers \ - openssl-dev \ - musl-dev \ - libffi-dev \ - python3-dev \ - cargo \ - git \ - && python tools/pipstrap.py \ - && python tools/pip_install.py --no-cache-dir \ - --editable src/acme \ - --editable src/certbot \ - && apk del .build-deps \ - && rm -rf ${HOME}/.cargo diff --git a/tools/docker/plugin/Dockerfile b/tools/docker/plugin/Dockerfile deleted file mode 100644 index 863efd105..000000000 --- a/tools/docker/plugin/Dockerfile +++ /dev/null @@ -1,14 +0,0 @@ -# Certbot image to build on (e.g. certbot/certbot:amd64-v0.35.0) -ARG BASE_IMAGE -FROM ${BASE_IMAGE} - -# Qemu Arch (x86_64, arm, ...) -ARG QEMU_ARCH -ENV QEMU_ARCH=${QEMU_ARCH} -COPY qemu-${QEMU_ARCH}-static /usr/bin/ - -# Copy Certbot DNS plugin code -COPY . /opt/certbot/src/plugin - -# Install the DNS plugin -RUN python tools/pip_install.py --no-cache-dir --editable /opt/certbot/src/plugin