RewriteCond/RewriteRule blues
			1 post
			 • Page 1 of 1
		
	
RewriteCond/RewriteRule blues
I have an internal server http://munin.lan which I want to reach from outside the lan using the address https://mysite.com/munin.
I have therefore written the following:
That, however, does not work. The log says:
What am I doing that is wrong?
			
		I have therefore written the following:
- Code: Select all
 # if the user is trying to reach the munin server, redirect to munin.lan
RewriteCond %{REQUEST_URI} /munin [nocase]
RewriteRule ^(http|https)://(mysite.com/munin(.*?)) http://munin.lan [nocase, P, L]
# for all other cases, apply the following rule
RewriteRule (.*)$ http://haus.lan/$1 [nocase, P, last]
That, however, does not work. The log says:
- Code: Select all
 RewriteCond: input='/munin' pattern='/munin' => matched
forcing proxy-throughput with http://haus.lan/munin
go-ahead with proxy request http://haus.lan/munin [OK]
Rewrite URL to >> /muninx.rwhlp?p=0
rewrite 'munin' -> '/muninx.rwhlp?p=0'
internal redirect with /muninx.rwhlp?p=0 [INTERNAL REDIRECT]
What am I doing that is wrong?
			1 post
			 • Page 1 of 1
		
	
Who is online
Users browsing this forum: No registered users and 10 guests