【发布时间】:2018-10-12 11:14:57
【问题描述】:
我有一个调用外部 URL 的应用程序。 当我尝试在 localhost 中运行它时,只会加载 localhost 中的一些静态 HTML 文件。
不会加载位于外部 URL 上的任何文件。它返回 404 未找到错误。
我正在使用 Apache 服务器和 Tomcat 来运行应用程序。
我的 Httpd.conf 文件有以下变化:
<VirtualHost *:80>
ProxyPreserveHost On
ProxyRequests On
ProxyVia On
ServerName localhost
ServerAlias *.localhost
ProxyPass /ab-ux-sass http://localhost:8080/ab-ux-sass
ProxyPassReverse /ab-ux-sass http://localhost:8080/ab-ux-sass
ProxyPass /ux-services https://boot.lender.com/ux-services
ProxyPassReverse /ux-services
https://boot.lender.com/ux-services
</VirtualHost>
需要进行哪些配置更改?
【问题讨论】:
-
请举例说明您尝试请求的 URL:哪些有效,哪些无效。
-
@ChristopherSchultz 现在可以正常工作了...最初本地主机链接可以正常工作,但 boot.lender.com 没有
标签: apache tomcat httpd.conf