From 2d98e8f2f0e31422a466eb66ef834b62ba853902 Mon Sep 17 00:00:00 2001 From: Daniel Berteaud Date: Tue, 9 Feb 2016 22:03:27 +0100 Subject: [PATCH] Fix ProxyPass handling logic --- .../etc/httpd/conf/httpd.conf/WebAppVirtualHost/50Content | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/WebAppVirtualHost/50Content b/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/WebAppVirtualHost/50Content index b59bfa5..dadf063 100644 --- a/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/WebAppVirtualHost/50Content +++ b/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/WebAppVirtualHost/50Content @@ -21,14 +21,14 @@ my @groups = split(/[;,]/, ($domain->prop('AllowGroups') || '')); # ProxyPass ? if ($target =~ m|https?://[\d\w\.\-/]*|){ $OUT .= " SetEnv proxy-nokeepalive 1\n" if ($keepalive eq 'yes'); - if ($proxy_acme eq 'disabled'){ - $OUT .= " ProxyPass /.well-known/acme-challenge/ !\n"; - } - elsif ($proxy_acme eq 'only'){ + if ($proxy_acme eq 'only'){ $OUT .= " ProxyPass /.well-known/acme-challenge/ $target" . ".well-known/acme-challenge/\n"; $OUT .= " ProxyPassReverse / $target" . ".well-known/acme-challenge/\n"; } else{ + if ($proxy_acme eq 'disabled'){ + $OUT .= " ProxyPass /.well-known/acme-challenge/ !\n"; + } $OUT .= " ProxyPass / $target\n"; $OUT .= " ProxyPassReverse / $target\n"; }