apche 多端口配置及网站指向非apche默认的网站文件夹设置方法

softyun3年前服务器110

#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:httpd.apache.org/docs/2.2/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
NameVirtualHost *:81
NameVirtualHost *:82
NameVirtualHost *:83
NameVirtualHost *:84
NameVirtualHost *:85
NameVirtualHost *:86
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ServerName or ServerAlias in any <VirtualHost> block.
#
<VirtualHost *:81>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/www-nongye
         ServerName dede
         ErrorLog D:/AppServ/www/www-nongye/errornongye.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:82>
    <Directory "D:/AppServ/www-chinaec" >
        Options FollowSymLinks
        #Deny from all
        Allow from all
    </Directory>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www-chinaec
         ServerName dede
     DirectoryIndex index.php index
         ErrorLog D:/AppServ/www-chinaec/errornongjiale.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:83>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/www-05110
         ServerName dede
         ErrorLog D:/AppServ/www/www-05110/errornong05110.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:84>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/wordpress
         ServerName dede
         ErrorLog D:/AppServ/www/wordpress/errornongwordpress.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:85>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/magento
         ServerName dede
         ErrorLog D:/AppServ/www/magento/errormagento.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:86>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/magento1322
         ServerName dede
         ErrorLog D:/AppServ/www/magento1322/errormagento1322.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:88>
         ServerAdmin jsw7001@hotmail
         DocumentRoot D:/AppServ/www/www-nongjiale
         ServerName dede
         ErrorLog D:/AppServ/www/www-nongjiale/errornongjiale.log
         CustomLog logs/dummy-host2.appservnetwork-access_log common
</VirtualHost>
<VirtualHost *:80>
    ServerAdmin webmaster@dummy-host2.x
    DocumentRoot "C:/Apache2.2/docs/dummy-host2.x"
    ServerName dummy-host2.x
    ErrorLog "logs/dummy-host2.x-error.log"
    CustomLog "logs/dummy-host2.x-access.log" common
</VirtualHost>

免责声明:本文内容来自用户上传并发布,站点仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。请核实广告和内容真实性,谨慎使用。

相关文章

.htaccess文件写法之作用范围

有太多的朋友会碰到一个问题,那就是htaccess文件冲突的问题,比如说,一个站点,全站是用伪静态,并且是用的虚拟主机,那就必须要用.htaccess文件规则来实现,同时用CMS文件做门户用DZ做BB...

什么是便宜域名注册,你需要知道的事情

1.便宜域名注册便宜域名注册是指在域名注册商处注册域名,以极低的价格获取域名的过程。很多域名注册商在促销或者节日等特定时间会推出一些超级优惠活动,如新用户注册、打折和优惠券等,让用户在获取域名的过程中...

服务器的操作系统到底是哪些,服务器的操作系统是什么

在计算机领域中,服务器的操作系统是指在服务器上运行的操作系统,它负责管理服务器硬件资源,为用户提供各种服务。服务器的操作系统通常具有高度的稳定性、可靠性、安全性和灵活性。常见的服务器操作系统包括:Wi...

服务器之家,服务器之家介绍

什么是服务器之家?服务器之家的起源和发展历程1.什么是服务器之家?服务器之家是一个面向企业和个人提供服务器租赁、托管、维护等服务的专业平台。它通过互联网与客户实现信息交互,让客户无需投资大量资金也能享...

使用phpStudy搭建php环境及安装各种php程序实战教程

PHPStudy集成最新的Apache+PHP+MySQL+phpMyAdmin+Zend Loader,8件套合集,支持Zend和rewrite,是非常方便、好用的PHP调试环境。该程序绿色小巧简易...

解析关于wamp启动是80端口被占用的问题

问题如下:网上有关于这个处理办法,说道:VS2010在更新了SP1后,会在开机时自动启动一个服务,占用WAMP的80端口,导致WAMP无法正常启动Apache。提示信息:Your port 80 is...