Sunday, September 22, 2013

Apache – how to configure VirtualHost(example)

<VirtualHost *:80>
    DocumentRoot “/var/www/html/pr1″
    ServerName rec.host.com
    ServerAlias rec3.host.com
    <Directory “/var/www/html/pr1″>
        Order Allow,Deny
        allow from all
        Options -Indexes
    </Directory>
    <Directory “/var/www/html/pr1/config”>
        Order Deny,Allow
        deny from all
    </Directory>
    <Directory “/var/www/html/pr1/dl”>
        Order Allow,Deny
        Allow from all
        Options +Indexes
    </Directory>

</VirtualHost>

No comments:

Post a Comment