域名重定向次数过多

域名重定向次数过多

我有一个 Apache 网络服务器。

我想设置一个反向代理来访问在端口 9090 上运行的本地应用程序。

这是我的 Apache 配置:

ProxyRequests Off

NameVirtualHost *:80
NameVirtualHost *:443

SSLProtocol ALL -SSLv2 -SSLv3
SSLHonorCipherOrder On
SSLCipherSuite ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA

# Redirect HTTP requests to HTTPS
<VirtualHost *:80>
    DocumentRoot "${SRVROOT}/htdocs/example.com/public_html"
    ServerName example.com
    ServerAlias example
    Redirect / https://www.example.com/
</VirtualHost>

<VirtualHost *:443>
    DocumentRoot "${SRVROOT}/htdocs/example.com/public_html"
    ServerName example.com
    ServerAlias example
    ProxyPass / http://127.0.0.1:9090/
    ProxyPassReverse / http://127.0.0.1:9090/
    ProxyPreserveHost On
    RequestHeader unset Origin
</VirtualHost>

配置不起作用。我收到错误:example.com 重定向您次数过多

该服务器托管在 Windows 10 EC2 AWS 实例上。

有人知道如何解决这个问题吗?

谢谢。

相关内容