我正在尝试设置具有多个 Web 应用程序的服务器,这些应用程序都将通过 apache VirtualHost(运行在同一台服务器上的 apache)提供服务。我的主要限制是每个 Web 应用程序都必须使用 SSL 加密。在谷歌搜索了一段时间并查看了有关 stackoverflow 的其他问题后,我为 VirtualHost 编写了以下配置:
<VirtualHost 1.2.3.4:443>
ServerName host.domain.org
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
SSLProxyEngine On
ProxyRequests Off
ProxyPreserveHost On
ProxyPass / https://localhost:8443/
ProxyPassReverse / https://localhost:8443/
</VirtualHost>
即使https://host.domain.org:8443可以访问,但https://host.domain.org不能访问,这违背了我的虚拟主机配置的目的。Firefox 抱怨即使它成功连接到服务器,连接也被中断了。Chrome 返回错误 107:net::ERR_SSL_PROTOCOL_ERROR。
最后我还应该提到,当我不使用 SSL 时,虚拟主机工作得非常好。
我怎样才能使这项工作?
谢谢