Skip to content

Commit a4cf5dd

Browse files
committed
Updated Nginx Proxy Manager to version 2.11.3.
1 parent e3f8da9 commit a4cf5dd

File tree

7 files changed

+35
-150
lines changed

7 files changed

+35
-150
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ARG DOCKER_IMAGE_VERSION=
99

1010
# Define software versions.
1111
ARG OPENRESTY_VERSION=1.19.9.1
12-
ARG NGINX_PROXY_MANAGER_VERSION=2.10.4
12+
ARG NGINX_PROXY_MANAGER_VERSION=2.11.3
1313
ARG NGINX_HTTP_GEOIP2_MODULE_VERSION=3.3
1414
ARG LIBMAXMINDDB_VERSION=1.5.0
1515
ARG BCRYPT_TOOL_VERSION=1.1.2

src/nginx-proxy-manager/build.sh

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,14 @@ sed -i "s/\"version\": \"0.0.0\",/\"version\": \"${NGINX_PROXY_MANAGER_VERSION}\
7474
sed -i "s/\"version\": \"0.0.0\",/\"version\": \"${NGINX_PROXY_MANAGER_VERSION}\",/" /tmp/nginx-proxy-manager/backend/package.json
7575

7676
log "Patching Nginx Proxy Manager backend..."
77-
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/pip-install.patch
78-
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/remove-certbot-dns-oci.patch
79-
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/powerdns-fix.patch
80-
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/http2-support-fix.patch
81-
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/reachability-test-fix.patch
77+
PATCHES="
78+
pip-install.patch
79+
remove-certbot-dns-oci.patch
80+
"
81+
for P in $PATCHES; do
82+
echo "Applying $P..."
83+
patch -p1 -d /tmp/nginx-proxy-manager < "$SCRIPT_DIR"/"$P"
84+
done
8285

8386
cp -r /tmp/nginx-proxy-manager /app
8487

@@ -166,7 +169,7 @@ sed -i 's|user npm;|#user npm;|' $ROOTFS/etc/nginx/nginx.conf
166169
sed -i 's|/tmp/nginx/body|/var/tmp/nginx/body|' $ROOTFS/etc/nginx/nginx.conf
167170

168171
# Fix the logrotate config.
169-
sed -i 's|root root|app app|' $ROOTFS/etc/logrotate.d/nginx-proxy-manager
172+
sed -i 's|npm npm|app app|' $ROOTFS/etc/logrotate.d/nginx-proxy-manager
170173
sed -i 's|/run/nginx.pid|/run/nginx/nginx.pid|' $ROOTFS/etc/logrotate.d/nginx-proxy-manager
171174
sed -i 's|logrotate /etc/logrotate.d/nginx-proxy-manager|logrotate -s /config/logrotate.status /etc/logrotate.d/nginx-proxy-manager|' $ROOTFS/opt/nginx-proxy-manager/setup.js
172175
sed -i 's|/data/logs/\*/access.log|/data/logs/access.log|' $ROOTFS/etc/logrotate.d/nginx-proxy-manager

src/nginx-proxy-manager/http2-support-fix.patch

Lines changed: 0 additions & 14 deletions
This file was deleted.
Lines changed: 10 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,11 @@
1-
diff --git a/backend/internal/certificate.js b/backend/internal/certificate.js
2-
index da104a2..730d826 100644
3-
--- a/backend/internal/certificate.js
4-
+++ b/backend/internal/certificate.js
5-
@@ -871,7 +871,7 @@ const internalCertificate = {
6-
const escapedCredentials = certificate.meta.dns_provider_credentials.replaceAll('\'', '\\\'').replaceAll('\\', '\\\\');
7-
const credentialsCmd = 'mkdir -p /etc/letsencrypt/credentials 2> /dev/null; echo \'' + escapedCredentials + '\' > \'' + credentialsLocation + '\' && chmod 600 \'' + credentialsLocation + '\'';
8-
// we call `. /opt/certbot/bin/activate` (`.` is alternative to `source` in dash) to access certbot venv
9-
- const prepareCmd = '. /opt/certbot/bin/activate && pip install --no-cache-dir ' + dns_plugin.package_name + (dns_plugin.version_requirement || '') + ' ' + dns_plugin.dependencies + ' && deactivate';
10-
+ const prepareCmd = 'pip install --no-cache-dir ' + dns_plugin.package_name + (dns_plugin.version_requirement || '') + ' ' + dns_plugin.dependencies;
11-
12-
// Whether the plugin has a --<name>-credentials argument
13-
const hasConfigArg = certificate.meta.dns_provider !== 'route53';
14-
diff --git a/backend/setup.js b/backend/setup.js
15-
index a4b51c9..6d3d3e3 100644
16-
--- a/backend/setup.js
17-
+++ b/backend/setup.js
18-
@@ -189,7 +189,7 @@ const setupCertbotPlugins = () => {
19-
});
20-
21-
if (plugins.length) {
22-
- const install_cmd = '. /opt/certbot/bin/activate && pip install --no-cache-dir ' + plugins.join(' ') + ' && deactivate';
23-
+ const install_cmd = 'pip install --no-cache-dir ' + plugins.join(' ');
24-
promises.push(utils.exec(install_cmd));
25-
}
1+
--- a/backend/lib/certbot.js
2+
+++ b/backend/lib/certbot.js
3+
@@ -63,7 +63,7 @@
4+
plugin.version = plugin.version.replace(/{{certbot-version}}/g, CERTBOT_VERSION_REPLACEMENT);
5+
plugin.dependencies = plugin.dependencies.replace(/{{certbot-version}}/g, CERTBOT_VERSION_REPLACEMENT);
266

7+
- const cmd = '. /opt/certbot/bin/activate && pip install --no-cache-dir ' + plugin.dependencies + ' ' + plugin.package_name + plugin.version + ' ' + ' && deactivate';
8+
+ const cmd = 'pip install --no-cache-dir ' + plugin.dependencies + ' ' + plugin.package_name + plugin.version;
9+
return utils.exec(cmd)
10+
.then((result) => {
11+
logger.complete(`Installed ${pluginKey}`);

src/nginx-proxy-manager/powerdns-fix.patch

Lines changed: 0 additions & 13 deletions
This file was deleted.

src/nginx-proxy-manager/reachability-test-fix.patch

Lines changed: 0 additions & 70 deletions
This file was deleted.
Lines changed: 15 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,19 @@
11
Because of the Oracle Cloud Infrastructure DNS plugin dependencies, installing
22
it causes certbot to be downgraded, which then break any execution of certbot.
3-
--- a/global/certbot-dns-plugins.js
4-
+++ b/global/certbot-dns-plugins.js
5-
@@ -437,20 +437,6 @@ dns_netcup_api_password = abcdef0123456789abcdef01234567abcdef0123`,
6-
full_plugin_name: 'dns-nsone',
3+
--- a/global/certbot-dns-plugins.json
4+
+++ b/global/certbot-dns-plugins.json
5+
@@ -437,14 +437,6 @@
6+
"credentials": "dns_nsone_api_key = MDAwMDAwMDAwMDAwMDAw",
7+
"full_plugin_name": "dns-nsone"
78
},
8-
//####################################################//
9-
- oci: {
10-
- display_name: 'Oracle Cloud Infrastructure DNS',
11-
- package_name: 'certbot-dns-oci',
12-
- package_version: '0.3.6',
13-
- dependencies: 'oci',
14-
- credentials: `[DEFAULT]
15-
-user = ocid1.user.oc1...
16-
-fingerprint = xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx
17-
-tenancy = ocid1.tenancy.oc1...
18-
-region = us-ashburn-1
19-
-key_file = ~/.oci/oci_api_key.pem`,
20-
- full_plugin_name: 'dns-oci',
9+
- "oci": {
10+
- "name": "Oracle Cloud Infrastructure DNS",
11+
- "package_name": "certbot-dns-oci",
12+
- "version": "~=0.3.6",
13+
- "dependencies": "oci",
14+
- "credentials": "[DEFAULT]\nuser = ocid1.user.oc1...\nfingerprint = xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx\ntenancy = ocid1.tenancy.oc1...\nregion = us-ashburn-1\nkey_file = ~/.oci/oci_api_key.pem",
15+
- "full_plugin_name": "dns-oci"
2116
- },
22-
- //####################################################//
23-
online: {
24-
display_name: 'Online',
25-
package_name: 'certbot-dns-online',
17+
"ovh": {
18+
"name": "OVH",
19+
"package_name": "certbot-dns-ovh",

0 commit comments

Comments
 (0)