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

softyun3年前服务器46

#
# 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>

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

相关文章

宝塔面板如何设置伪静态规则?

宝塔面板后台集成了站点伪静态规则设置选项,无需更改Linux服务器conf文件配置即可自定义站点伪静态规则,真的很方便,另外宝塔为市面上常见的程序提供了自带的伪静态规则,只需要鼠标点选即可。新手站长网...

电信主机托管是什么,选择最佳的托管方案

电信主机托管是指将服务器等计算机设备交由电信运营商进行管理、维护、监控等服务的一种方式。其特点是维护成本低、服务质量高、网络安全可靠。托管方案包括机柜托管、服务器托管、云托管等多种形式,在选择方案时需...

什么是最网站空间,最网站空间的特点及使用方法

1.最网站空间是什么?最网站空间指的是非官方运营的服务器,由个人或团体自主搭建或租用服务器资源,提供网站空间的服务。例如,一款网游有官方运营的服务器,也有玩家自行搭建的最服务器,这些最服务器便需要购买...

代理服务器是什么意思,代理服务器的含义

代理服务器是一种网络应用服务,在客户端和服务器之间充当中间人的角色,接收来自客户端的请求,并将其转发给目标服务器。代理服务器在网络请求传输中扮演重要的角色,能够提高网络通信效率和安全性。代理服务器可以...

为什么需要租用虚拟主机,如何租用虚拟主机

1.虚拟主机是什么虚拟主机是指在一台服务器上分配多个独立的空间给多个客户使用。每个客户的网站可以独立运行,互不影响。虚拟主机相对于独立主机,价格更低廉,适合个人或小型企业使用。虚拟主机还提供了管理界面...

phpstudy是什么?phpstudy有什么用?

phpStudy是一个PHP调试环境的程序集成包。该程序包集成最新的Apache+PHP+MySQL+phpMyAdmin+ZendOptimizer,一次性安装,无须配置即可使用,是非常方便、好用的...