httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike <mike.li...@levrah.net>
Subject [users@httpd] Server-Wide Rewrite w/out Multiple .htaccess Files
Date Wed, 29 Jan 2003 22:00:35 GMT
Hello everyone.

I'm trying to find a way to manage (identical) rewrite statements for 
multiple vhosts. I have no syntax problems with the rewrite statements 
themselves. We have them working already on all vhosts, and have had for 
quite some time.

Think of a dozen (or more) .htaccess files.
Each having the same/identical rewrite statements in them.
Alot of (otherwise) unnecessary duplication...
...looking for a way to have "server-wide" rewrites that will work on/for 
all vhosts.

I would like to just vi one file, restart web service (if necessary?) and 
logout. :)  But, what happens now is that I find myself updating and 
re-uploading multiple .htaccess files when we need to add (or delete) an 
entry. It's not difficult. But it is getting tediously annoying. :)

Soooo, I'm looking to see if anyone knows a good way to get around having 
to update and upload multiple .htaccess files? I've tried a couple of 
methods already; with limited success. Here is a brief outline with results:

1) Added test rewrite statements in httpd.conf before/above vhosts 
directives using directory / as the starting point and [F] to display 
forbidden page. This seems to work, but not consistently.

2) Same as #1 but the rewrites were added after/below vhosts directives. 
Same result.

The rewrite statement used during my tests was a simple statement to deny 
access - show forbidden page - based on my connection IP. This way, it 
would only affect me and the vhosts would remain up and web accessible 
otherwise.

Anyone have any ideas?
Other ways - I'm not thinking of - to do the same thing?

Thanks!
-mike

P.S. I know it's not prudent to mess around with updating the httpd.conf 
file itself very much. So once I get the process working properly and 
consistently, I plan to put the statements into a file and use Include to 
include that file in httpd.conf. This assumes someone doesn't tell me 
there's a better way to do it, of course. :-)


---------------------------------------------------------------------
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


Mime
View raw message