apache httpd-vhosts.conf文件配置

 

NameVirtualHost *:80

NameVirtualHost *:8008

 

#<VirtualHost *:80>
#    ServerAdmin [email protected]
#    DocumentRoot /usr/local/apache/htdocs
#    ServerAlias www.dummy-host.example.com
#    ErrorLog "logs/dummy-host.example.com-error_log"
#    CustomLog "logs/dummy-host.example.com-access_log" common
#</VirtualHost>

 

 

#<VirtualHost *:80>
#    ServerName abc
#    ServerAlias www.abc.cn
#    ServerAlias www.abc.com.cn
#    ServerAlias www.test.com
#    ProxyPreserveHost on
#    ProxyRequests On
#    ProxyVia On
#    ProxyPass /jinluopan http://localhost:8080/web/
#    ProxyPassReverse /web/ ajp://localhost:8009/web/
#</VirtualHost>

 


<VirtualHost *:80>
#    ServerName abc
ServerName http://www.abc.com.cn
DocumentRoot /usr/local/apache/htdocs/web
</VirtualHost>

 

<VirtualHost *:80>
ServerName abc.com.cn
DocumentRoot /usr/local/apache/htdocs/web
</VirtualHost>

 

<VirtualHost *:80>
ServerName http://www.test.com
DocumentRoot /usr/local/apache/htdocs/web_test
</VirtualHost>

 

<VirtualHost *:80>
ServerName www.888888.com
ServerAlias www.666666.com
ProxyPreserveHost on
ProxyRequests On
ProxyVia On
ProxyPass / http://192.168.1.40/
ProxyPassReverse / http://192.168.1.40/
#    ServerAlias www.dummy-host.example.com
#    ErrorLog "logs/dummy-host.example.com-error_log"
#    CustomLog "logs/dummy-host.example.com-access_log" common
</VirtualHost>


<VirtualHost *:8008>
ServerName www.888888.com
ServerAlias www.666666.com
ProxyPreserveHost on
ProxyRequests On
ProxyVia On
ProxyPass / http://192.168.1.40:8008/
ProxyPassReverse / http://192.168.1.40:8008/
#    ServerAlias www.dummy-host.example.com
#    ErrorLog "logs/dummy-host.example.com-error_log"
#    CustomLog "logs/dummy-host.example.com-access_log" common
</VirtualHost>

 

<VirtualHost *:80>
     ServerName http://oa.abc.com.cn
     DocumentRoot /usr/local/apache/htdocs/oa
</VirtualHost>

 

<VirtualHost *:80>
     ServerName http://www.abc.cn
     DocumentRoot /usr/local/apache/htdocs/web
</VirtualHost>

 

#<VirtualHost *:80>
#    ServerName http://stock.abc.cn
#     DocumentRoot /usr/local/apache/htdocs/stock
#</VirtualHost>


#<VirtualHost *:80>
#     ServerName http://www.top-solar.com.cn
#     DocumentRoot /usr/local/apache/htdocs/TopAna
#</VirtualHost>

 

 

 

你可能感兴趣的:(apache,Web,Access)