Skip to content

Commit f29304a

Browse files
committed
Fixed installation of certbot plugins and generation of certificates using DNS challenge.
1 parent 41a69ef commit f29304a

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

Dockerfile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,12 +252,13 @@ RUN \
252252

253253
# Adjust certbot config.
254254
sed-patch 's|/data/|/config/|g' /etc/letsencrypt.ini && \
255-
echo "logs-dir = /config/log/letsencrypt" >> /etc/letsencrypt.ini && \
256-
echo "work-dir = /config/letsencrypt-workdir" >> /etc/letsencrypt.ini && \
257255

258256
# Change client_body_temp_path.
259257
sed-patch 's|/tmp/nginx/body|/var/tmp/nginx/body|' /etc/nginx/nginx.conf && \
260258

259+
# Fix the pip install command.
260+
sed-patch 's|pip3 install |pip3 install --user |' /opt/nginx-proxy-manager/internal/certificate.js && \
261+
261262
# Redirect `/data' to '/config'.
262263
ln -s /config /data && \
263264

@@ -279,6 +280,10 @@ RUN \
279280
# Make sure letsencrypt certificates are stored in persistent volume.
280281
ln -s /config/letsencrypt /etc/letsencrypt && \
281282

283+
# Make sure some default certbot directories are stored in persistent volume.
284+
ln -s /config/letsencrypt-workdir /var/lib/letsencrypt && \
285+
ln -s /config/log/letsencrypt /var/log/letsencrypt && \
286+
282287
# Cleanup.
283288
del-pkg build-dependencies && \
284289
find /opt/nginx-proxy-manager -name "*.h" -delete && \

rootfs/startapp.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
set -e # Exit immediately if a command exits with a non-zero status.
44
set -u # Treat unset variables as an error.
55

6+
export HOME=/config
67
export NODE_ENV=production
78
export SUPPRESS_NO_CONFIG_WARNING=1
89

0 commit comments

Comments
 (0)