2

Within a multi-server shared hosting I am using this

RedirectMatch temp "/.well-known/acme-challenge/(.*)" "https://FOO.BAR.TLD/$1"

to redirect all Let's Encrypt requests to one server.

The problem: If someone (customer ;-) ) is using e.g.

RedirectPermanent / http://somewhereelse

the RedirectPermanent takes precedence over RedirectMatch (which is logical).

So I replaced my central rule with

RewriteEngine On
RewriteRule "^/.well-known/acme-challenge/(.*)" "https://FOO.BAR.TLD/$1" [L,R=302]

but even with the "L"-Flag, mod_alias (RedirectPermanent) is getting executed.

Does anyone see any chance to "fix" this so that my central rule is getting executed at any time?

BTW: I also tried to ensure that "my" rule is the last one (and the first one) in apache config by ordering file names, but the RedirectPermanent of the customer alwa

0 Answers0