From 7e7032c051d5a6d78c985118899adff28000b2ca Mon Sep 17 00:00:00 2001 From: Orko Garai Date: Thu, 18 Feb 2021 05:40:49 +0000 Subject: [PATCH] Prevent activating nginx config after editing disabled proxy host --- backend/internal/proxy-host.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/backend/internal/proxy-host.js b/backend/internal/proxy-host.js index b26e0566..09b8bca5 100644 --- a/backend/internal/proxy-host.js +++ b/backend/internal/proxy-host.js @@ -189,6 +189,10 @@ const internalProxyHost = { expand: ['owner', 'certificate', 'access_list.[clients,items]'] }) .then((row) => { + if (!row.enabled) { + // No need to add nginx config if host is disabled + return row; + } // Configure nginx return internalNginx.configure(proxyHostModel, 'proxy_host', row) .then((new_meta) => {