Board index Linux Apache

Moderator: chandranjoy

Sample VirtualHost entry for a domain in Apache

Postby chandranjoy » Sun Aug 21, 2011 3:35 pm

Core server Apache virtualhost config:
<VirtualHost *:80>
ServerName domain.com
ServerAlias http://www.domain.com

DocumentRoot /var/www/vhosts/domain.com/public_html
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/vhosts/domain.com/public_html/>
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order allow,deny
allow from all
</Directory>

ErrorLog /var/www/vhosts/domain.com/logs/error.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn

CustomLog /var/www/vhosts/domain.com/logs/access.log combined

ScriptAlias /cgi-bin/ /var/www/vhosts/domain.com/public_html/cgi-bin/

<Directory /var/www/vhosts/domain.com/public_html/cgi-bin>
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>

</VirtualHost>


:)
chandranjoy
Site Admin
 
Posts: 283
Joined: Fri Oct 23, 2009 11:19 pm

Return to Apache

Who is online

Users browsing this forum: No registered users and 1 guest


cron