【发布时间】:2020-04-06 08:27:16
【问题描述】:
我在 Azure Blob 存储中配置了一个前端网站,按照下一篇文章:
https://docs.microsoft.com/en-us/azure/cdn/cdn-map-content-to-custom-domain
我已成功配置此网站以显示我的自定义域:
我现在正在寻找如何配置正确的 301 重定向:
- http -> 301 -> https
- example.com -> 301 -> www.example.com
我读了这个部分:https://www.itinsights.org/Static-Websites-with-Azure-Part-4/#HTTP-to-HTTPs-redirection
但在我的天蓝色门户中,我看不到任何可以推送此 xml 规则或如何从界面配置重定向规则的部分。
<rule id="1111111" platform="http-large" status="active" version="0" custid="XXXXX">
<description>HTTP to HTTPS</description>
<match.request-scheme value="http">
feature.url-redirect code="301" pattern="/XXXXXXX/staticwebsitede/(.*)" value="https://www.staticwebsite.de/$1" />
</match.request-scheme>
</rule>
编辑 根据接受的答案,我已联系 Azure 支持以查看是否可以迁移。 对于 example.com 到 www.example.com 的重定向,我使用了我的域注册的 Web 转发功能。
【问题讨论】: