[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: apache with VirtualHosts's stored in MySQL database



On Tue, 3 Jan 2006, jack wrote:

Does anyone know of any good ways of storing large amounts of VirtualHosts in a mysql database?

I'd eventually like to setup a web frontend for ease of administration.

mod_rewrite http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html#RewriteMap

allows reading information from a "Map"

the  Apache URL Rewriting Guide has a section on "Mass Virtual Hosting"
http://httpd.apache.org/docs/1.3/misc/rewriteguide.html

I use a text map similar to the example, however you could have a program as a map that queries the database, or just generate reports from the database (with cron) and use the text map.

this method has its drawbacks, (no virtual host container for unique settings) but is much easier for me to add (and move) domains.

I've made a few changes from example shown. contact me privately for my version.

Steve



Reply to: