我在其中一个应用服务内的 Azure 仪表板上运行了“诊断和解决问题”,然后我收到了这个严重的风险警报:“由于重定向,应用程序评估不正常。”。
建议的措施是:
If the application has HTTP to HTTPS redirectoin, consider one of the following solutions.
a. Enable 'HTTPs Only' from the TLS/SSL settings blade for the respective App Service. This will force health check pings to over 443.
b. Modify the Application logic/ad a URL Rewrite rule so that requests from the user agents – ReadyForRequest/1.0+(HealthCheck) & HealthCheck/1.0 are not redirected.
我已经按照 (a) 点的建议启用了“仅限 HTTPs”,但我不知道如何执行 (b) 点。如何修改应用程序逻辑/广告 URL 重写规则,以便来自用户代理的请求 - ReadyForRequest/1.0+(HealthCheck)
&HealthCheck/1.0
不被重定向?
目前,我启用了健康检查并将健康检查路径设置为/
.
在此之前感谢您的帮助。