You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Mark-Nathaniel Weisman <ma...@outlander.us> on 2002/10/05 18:38:42 UTC

[users@httpd] mod_rewrite

Hello List,
  I've got a quick question that maybe someone can answer. I'd like to redirect requests for one of the domains I host. I've got about 10 domains in all, and currently I use the <virtualhost> option to point all the domains to directories on this server. I'd like to move one of the domains over to another internal server. However, I want any requests for a specific domain to go over to the new server.
Currently in my httpd.conf I've got;

RewriteEngine on
RewriteLogLevel 0

RewriteRule	^/mystic$ http://www.mystic1.net/ [R]
RewriteRule	^/mystic/$ http://192.168.x.3/ [P]
RewriteRule	^/mystic/(.*)$ http://192.168.x.3/$1 [P,L]

ProxyRequests		on
NoCache		*
ProxyPassReverse	/mystic/  http://192.168.x.3/

A little further down I have;
<virtualhost 192.168.x.2:80>
	ServerAdmin	hostmaster@mystic1.net
	DocumentRoot	/usr/local/www/data/mystic1
	ServerName	www.mystic1.net
	ErrorLog
	CustomLog
</virtualhost>

I want to redirect any request for this domain to another internal server, how exactly do I do this? Any help would be greatly appreciated.

	Mark

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org