Hello Sajjad Ahmad
I understand you were unable to access the custom domain mapped to either the storage account static website or Azure Front Door service. This issue can occur if the custom domain is not registered on the storage account as shown below:
Storage account --> Networking --> Custom domain
Once you register the custom domain on the storage account, the "request URI is invalid" error will disappear.
I tested it in my lab and successfully accessed the static website.
In your setup, I noticed that your custom domain is currently mapped to a storage account where the custom domain is not registered.
If you cannot see the custom domain option listed under networking settings, it means you enabled the hierarchical namespace feature when creating the storage account.
Refer :
- https://learn.microsoft.com/en-us/azure/storage/blobs/storage-custom-domain-name?tabs=azure-portal#step-3-register-your-custom-domain-with-azure
- https://learn.microsoft.com/en-us/answers/questions/1281180/i-cant-add-a-custom-sub-domain-to-azure-blob-stora
Since custom domains on the storage account don't support HTTPS, you need to use the Azure Front Door service.
From your screenshot, I can see that you have already added the custom domain and enabled SSL on Azure Front door using the AFD managed certificate. However, the CNAME record was not mapped to the Azure Front Door endpoint.
Also, ensure that the origin settings are correctly configured for the storage account.
- In the route settings: - Forwarding and Accepting protocols should be set to HTTPS
- Finally, map the custom domain to the AFD endpoint by creating a CNAME Record.
If the issue still persists, please let me know the error message on AFD.ev.commswift.com CNAME EVCommswift-hqg9d8bgewfth7gb.z02.azurefd.net
I hope this has been helpful!
If above is unclear and/or you are unsure about something add a comment below.
Please click "Accept" the answer as original posters help the community find answers faster by identifying the correct answer.