Skip to content

Branded URL

Sven Aelterman edited this page Feb 10, 2022 · 1 revision

These instructions show how you can create a custom, branded URL for your Storage-as-a-Service website.

TLS

When you set up a custom domain for your static web app, a free TLS certificate for the web app will be provisioned automatically.

Adding and Verifying a Custom Domain

  1. In the Azure Portal, navigate to your Static Web App and select Custom domains from the left menu.
  2. Select + Add.
  3. Enter the domain in the Domain name text box, e.g., storage.institution.edu.
  4. Select Next.
  5. Choose your validation method, CNAME or TXT. For this walkthrough, use CNAME validation. CNAME validation cannot be used with a root or apex domain. Refer to the Resources below for information on validating an apex domain such as storageservice.com.
  6. Add the CNAME record in your domain's DNS records.
  7. Select Add.

Azure will attempt to validate the domain name. If the validation is successful, you'll see a Ready status. Select Close.

Updating the Redirect and Logout URIs for the Azure AD Application Registration

When users sign in, Azure AD will only allow redirects to registered redirect URIs in the application registration. You will need to add a redirect URI for each custom domain you add to your static web app.

  1. Navigate to your static web app's application registration in Azure AD.
  2. Select Authentication on the left.
  3. In the Web platform configuration, select Add URI.
  4. Add the URI in the following format: https://storage.institution.edu/.auth/login/aad/callback.
  5. Modify the Front-channel logout URL by updating the auto-generated static web app domain name with your custom domain name. Note that only one custom domain is support for the logout URI. If you add multiple custom domains, set one as the default and use that domain as the logout URI.
  6. Select Save.

Testing the Branded URL

Navigate to the custom domain. Because the authentication to the application uses cookies, even if you were logged in to the application at the auto-generated URL, you will need to sign in again.

Resources

Review the Azure Static Web Apps docs for more details on adding a custom domain name.

Clone this wiki locally