Skip to content

Commit 102d2f2

Browse files
committed
Use the most recent certbot.
1 parent 12a30bf commit 102d2f2

File tree

1 file changed

+20
-3
lines changed

1 file changed

+20
-3
lines changed

Dockerfile

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,18 +179,35 @@ RUN \
179179
nodejs \
180180
py3-pip \
181181
sqlite \
182-
certbot \
183182
openssl \
184183
apache2-utils \
185184
logrotate \
186-
# For /opt/nginx-proxy-manager/bin/handle-ipv6-setting
185+
# For /opt/nginx-proxy-manager/bin/handle-ipv6-setting.
187186
bash \
188-
# For openresty
187+
# For openresty.
189188
pcre \
190189
&& \
191190
# Adjust the logrotate config file.
192191
sed-patch 's|^/var/log/messages|#/var/log/messages|' /etc/logrotate.conf
193192

193+
# Build and install certbot.
194+
RUN \
195+
add-pkg --virtual build-dependencies \
196+
build-base \
197+
python3-dev \
198+
libffi-dev \
199+
openssl-dev \
200+
cargo \
201+
&& \
202+
CARGO_HOME=/tmp/.cargo pip install --prefix=/usr certbot && \
203+
find /usr/lib/python3.8/site-packages -type f -name "*.so" -exec strip {} ';' && \
204+
find /usr/lib/python3.8/site-packages -type f -name "*.h" -delete && \
205+
find /usr/lib/python3.8/site-packages -type f -name "*.c" -delete && \
206+
find /usr/lib/python3.8/site-packages -type d -name tests -print0 | xargs -0 rm -r && \
207+
# Cleanup.
208+
del-pkg build-dependencies && \
209+
rm -rf /tmp/* /tmp/.[!.]*
210+
194211
# Install Nginx Proxy Manager.
195212
RUN \
196213
# Install packages needed by the build.

0 commit comments

Comments
 (0)