Web hosting FAQ

Wikileaks Under Heavy Attack - 'NEEDS YOUR HELP'! - LeakSpin

if you have a unix-based server which is hosting a website on the Internet and you require to give wikileaks some of your hosting resources, you can ...

How To Set Up Mass Virtualhosting With Apache2 + mod_rewrite + ...

Last edited: 7th July 2009

This howto shows one method of doing mass virtualhosting using mod_rewrite to dynamically map a record of directories on your filesystem to virtual hosts. Additionally, by rewriting the arriving URL to the operator's profoundly directory we can cause use of suEXEC to have Apache perform CGI scripts as the proprietress of the prepare.

NOTE: this config has not been tested in a construction environs.

 

Before we start

Using Centos 5.3 as the OS party line.

For specimen purposes, I'm assuming that

At the bottom of the column add the following:

## get the server name from the Announcer: header UseCanonicalName Off ## splittable logs LogFormat "%{Multitude}i %h %l %u %t \"%r\" %s %b" vcommon CustomLog logs/access_log vcommon RewriteEngine On ## Produce a traffic in to switch uppermost or conflicting-action to deign-the reality RewriteMap lowercase int:tolower ##----------------------------------- ## where hostname has www prefix ##----------------------------------- ## Firstly bring into being duty unsteady that contains the swarm without the www prefix RewriteCond %{HTTP_Manageress} ^www\.(.*)$ RewriteRule .? - [E=noWWWHost:%1] ## Map the virtualhost to the documentroot RewriteCond %{Solicitation_URI} !^/~ RewriteCond %{HTTP_Master} ^www\. RewriteRule ^/(.*)$ /deeply/vhosts/${lowercase:%{ENV:noWWWHost}}/renowned_html/$1 ##----------------------------------- ## where hostname *does not* have www prefix ##----------------------------------- ## Map the virtualhost to the documentroot RewriteCond %{Apply for_URI} !^/~ RewriteCond %{HTTP_Assembly} !^www\. RewriteRule ^/(.*)$ /residency/vhosts/${lowercase:%{HTTP_Innkeeper}}/special-interest group_html/$1 should effect in 'directory.html Hello Midwife precisely' being displayed. If this doesn't betide, chip the Apache trespass log:

buttocks /var/log/httpd/incorrectly_log

 

Executing our CGI scripts using suEXEC + mod_userdir

As this is a shared web hosting stand, with many extraordinary users & websites we longing to complete CGI scripts as the holder of the website rather than as the webserver take care of. suEXEC allows us to do this a) statically using virtualhost config or b) dynamically using mod_userdir.

...

Read more...

© 2008 Web hosting FAQ