[Azure] Is it possible to utilize the blob SAS URL in the custom error pages of the application gateway?

Rushikesh Gaidhani 161 Reputation points
2024-04-04T22:31:26.07+00:00

Hello,

I came across the "Create Application Gateway custom error pages" documentation, which states that for setting up custom error pages, the blob storage needs to be accessible directly.
So, can we utilize a Blob SAS URL in the custom error pages of the Application Gateway?

I tried a SAS URL with all the permissions but it failed with the following error,

Failed to save configuration changes to application gateway '<app-gw-name>'. Error: Custom error page for status code '502' has a URL 'https://<stg-acct>.blob.core.windows.net/custom-error-pages/error-page.html?<SAS-Token>' which does not point to a HTML file, for httpListeners <app-gw-resource-group>/providers/Microsoft.Network/applicationGateways/<app-gw-resource-name>/httpListeners/<https-listener-name>'><app-gw-name>/<app-gw-listener-name>.

When I enable public access to the blob, the application gateway successfully saves the configuration.
"https://<stg-acct>.blob.core.windows.net/app-gw-custom-error-pages/error-page.html"

Azure Application Gateway
Azure Application Gateway
An Azure service that provides a platform-managed, scalable, and highly available application delivery controller as a service.
960 questions
0 comments No comments
{count} votes

Accepted answer
  1. ChaitanyaNaykodi-MSFT 22,941 Reputation points Microsoft Employee
    2024-04-04T23:04:19.2866667+00:00

    @Rushikesh Gaidhani Thank you for reaching out.

    I understand you wish to know if you can use Blob SAS URL in the custom error pages of the Application Gateway.

    The answer is actually no. This is by design the storage account must be publicly accessible and there is no workaround possible. Even Blob SAS URL is not supported. I will work with the doc author here and see if I can add note about Blob SAS URL in the documentation.

    Hope this helps! Please let me know if you have any questions. Thank you!


    ​​Please "Accept the answer" if the information helped you. This will help us and others in the community as well.


0 additional answers

Sort by: Most helpful