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

softyun3年前服务器108

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

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

相关文章

免费的网站服务器能否提供稳定的服务,免费的网站服务器的优点和缺点

1.什么是免费的网站服务器?免费的网站服务器是指提供网页托管服务的服务器,其提供的服务不需要收取任何费用。这种服务器可以帮助网站管理员快速地建立自己的网站,且无需担心高昂的服务器租用费用和维护成本。2...

Docker构建Tomcat Web服务器与Tomcat如何优化

Tomcat是由Apache软件基金会下属的Jakarta项目开发的一个Servlet容器,按照Sun Microsystems提供的技术规范,实现了对Servlet和JavaServer Page(...

东莞虚拟主机好用吗,东莞虚拟主机介绍

1.东莞虚拟主机东莞虚拟主机是指使用虚拟化技术将一台物理主机分割成多个虚拟主机,每个虚拟主机都可以独立运行操作系统和应用程序。与传统的独立主机相比,虚拟主机价格更为经济实惠,适合中小型企业或个人用户。...

windows下三种web服务器搭建方式

一、第一种方法(live-server)1、安装方法:Npm安装: npm install -g live-server(前提是先安装node.js)然后在所在项目目录下,打开命令行工具,输入 liv...

Apache中.htaccess文件功能

作为用户,所能使用的命令受到限制。管理员可以通过Apache 的AllowOverride指令来设置.子目录中的指令会覆盖更高级目录或者主服务器配置文件中的指令。一、错误文档的定位(1)常用的客户端请...

如何找到绍兴服务器租用服务,优质绍兴服务器租用服务最

1.什么是绍兴服务器租用?绍兴服务器租用是在绍兴地区提供给个人和企业的一种服务器租赁服务。租用方可以选择租用自己需要的服务器配置,并按照租期支付租金。2.绍兴服务器租用有哪些优势?与自建服务器相比,绍...