Vhost mod rewrite

techlists at phpcoderusa.com techlists at phpcoderusa.com
Wed Jun 11 17:06:11 MST 2014



Hi,

I just set up a new CentOS 6.5 LAMP box.  I am in the process of 
configuring the vhosts.

I created a file /etc/httpd/conf.d/vhosts.conf and the docroot to go 
with the vhost definition.  So far so good.

What I am wondering about is if I can do something like this in the 
vhost.conf file:

<VirtualHost *:80>

    <Directory /home/username/public_html/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        allow from all
    </Directory>

     DocumentRoot /home/username/public_html
     ServerName domain.tld
</VirtualHost>


Or would it be more proper to do something like this:

<Directory /home/username/public_html/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        allow from all
</Directory>


<VirtualHost *:80>
     DocumentRoot /home/username/public_html
     ServerName domain.tld
</VirtualHost>



Thanks in advance for your input!!

Keith


More information about the PLUG-discuss mailing list