diff --git a/roles/copr/backend/templates/lighttpd/lighttpd.conf b/roles/copr/backend/templates/lighttpd/lighttpd.conf index 84efc0bc2c..900e766656 100644 --- a/roles/copr/backend/templates/lighttpd/lighttpd.conf +++ b/roles/copr/backend/templates/lighttpd/lighttpd.conf @@ -467,7 +467,7 @@ server.upload-dirs = ( "/var/tmp" ) # we need to have this twice, once for IPv4 and once for IPv6, see: # https://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config#Recommended-IPv6-setup -{% if not devel %} +{% if letsencrypt is not defined %} # production still uses normal configuration $SERVER["socket"] == "{{ https_bind }}" { ssl.engine = "enable" @@ -482,10 +482,6 @@ $SERVER["socket"] == "{{ https_bind }}" { # devel runs on letsencrypt -# Used for letsencrypt validation -$HTTP["url"] =~ "^/.well-known/" { - dir-listing.activate = "enable" -} # Enable HTTPS $SERVER["socket"] == "{{ https_bind }}" { @@ -504,6 +500,13 @@ $SERVER["socket"] == "{{ https_bind }}" { {% endif %} {% endfor %} +{% if letsencrypt is defined %} +# Used for letsencrypt validation +$HTTP["url"] =~ "^/.well-known/" { + dir-listing.activate = "enable" +} +{% endif %} + url.redirect = ( "^/results/sgallagh/cockpit-preview/(.+)" => "/results/@cockpit/cockpit-preview/$1" ) url.redirect += ( "^/results/(.*)/(.*)/mageia-(.*)-i386(.*)" => "/results/$1/$2/mageia-$3-i586$4" )