나는 여러 개의 도메인에 응답하는 자바 애플리케이션을 가지고 있으며 각 도메인마다 특정 아파치 가상 호스트를 사용한다. 이것은 Apache가 정적 인 자원을 제공하기 위해 Tomcat보다 빠르기 때문입니다.아파치 가상 호스트와 "동적"도메인
필요성은 런타임에 재시작 아파치 구성없이 수행해야합니다.
AddType text/html .html .shtml
AddOutputFilter INCLUDES .html .shtml
NameVirtualHost *:80
UseCanonicalName Off
<VirtualHost *:80>
ServerName domain.com
ServerAlias *
# Define virtual host directory, using entire domain
VirtualDocumentRoot /path/to/whosts/%0
# Define directory access
<Directory "/path/to/whosts/">
Options -Indexes MultiViews +Includes
Order allow,deny
Allow from all
</Directory>
# Define Java Proxies
<Proxy *>
AddDefaultCharset Off
Order deny,allow
Allow from all
</Proxy>
# Allow Libs (static resources) to access apache directly
ProxyPass /libs !
ProxyPass/ajp://localhost:8009/
ProxyPassReverse/ajp://localhost:8009/
</VirtualHost>
내가 www.domain.com에 액세스하려고하면 때문, 잘 작동하지 않습니다, domain.com에 대한 접근과 다른 : 아래에 설명 된대로 은 내가한다 VirtualDocumentRoot 지시자를 사용하고이 작업을 수행하려면 .
www.domain.com에서 domain.com으로 기호 링크를 등록하는 것이 좋습니다 생각하십니까 ???
다른 방법이 있습니까? 정말 아파치 관리에 가난한 ...
고마워요!
Ciao, Davide.