aleix's blog

Split <VirtualHost> directives into multiple files

15 February 2007 7:57 pm (apache | python)

Yesterday, I found out that I needed an application to split the virtual hosts of an Apache 1.3 configuration into separate files so I could use them in the sites-available/sites-enabled Debian's Apache 2 way. I googled just a bit and I did not find anything so I did my own one (vhost-split.py).

Just pass it the configuration file and the script will generate a bunch of files named with the ServerName variable found in each virtual host. Note that repeated entries will generate separate files (www.mydomain.com, www.mydomain.com-1, ...). The script will also report commented entries.

3 responses

  1. Bst says:

    Thanksss you save my day

  2. Write My Essay For Me says:

    Science Channel’s are giving a complete knowledge to its viewers about every thing students write done dissertation on this subjects and show its importance.

  3. Electronics Engineering Assignment Help Online says:

    Great info! I recently came across your blog and have been reading along. I thought I would leave my first comment. I don’t know what to say except that I have

Leave a Reply