码迷,mamicode.com
首页 > Web开发 > 详细

Apache 虚拟主机配置案例

时间:2016-09-22 18:27:42      阅读:160      评论:0      收藏:0      [点我收藏+]

标签:apache   虚拟主机   

NameVirtualHost *:80
<VirtualHost *:80>
    ServerAdmin admin@free.com
    DocumentRoot "/usr/local/apache/htdocs"
    ServerName www.free.com
    ErrorLog "logs/www.free.com.error.log"
    CustomLog "logs/www.free.com.access.log" combined
    <Directory "/usr/local/apache/docs">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.php index.htm
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>
<VirtualHost *:80>
    ServerAdmin admin@free.com
    DocumentRoot "/data/html/wordpress"
    ServerName blog.free.com
#ServerAlias blog1.free.com
    ErrorLog "logs/blog.free.com.error.log"
    CustomLog "logs/blog.free.com.access.log" combined
    <Directory "/data/html/wordpress">
        Options Indexes FollowSymLinks
        DirectoryIndex index.html index.php index.htm
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>


本文出自 “眼眸刻着你的微笑” 博客,请务必保留此出处http://dengaosky.blog.51cto.com/9215128/1855311

Apache 虚拟主机配置案例

标签:apache   虚拟主机   

原文地址:http://dengaosky.blog.51cto.com/9215128/1855311

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!