Azure Static Web Apps' custom domain are differently working

LYC 0 Reputation points
2024-11-12T01:06:43.2966667+00:00

I'm trying to redirect from non-www domain to www domain with AzureFrontDoor.

Before this, I must add both custom domains, 'www.my_domain.co.kr' and 'my_domain.co.kr'.

However, when I add those tasks with two webapps(test-server and product-server) with TXT records, they worked differently.

Test-server app showed me 'Add a CNAME, ALIAS or A record' at 'action' column in 'Custom domains' tab, and its frontdoor operates normally.

Product-server didn't show me above words at 'action' column, and frontdoor doesn't work at all. When I access to 'my_domain.co.kr' of product-server, it shows me 'DNS_PROBE_FINISHED_NXDOMAIN' error, while another app's non-www domain redirects me into www domain properly.

I think this problem is derived from above difference between test and product server's custom domian and 'action'. Other options of web apps are not different from each other.

I want to know why this problem happens, and how can I resolve this one. I need your help!

Azure Front Door
Azure Front Door
An Azure service that provides a cloud content delivery network with threat protection.
696 questions
Azure Static Web Apps
Azure Static Web Apps
An Azure service that provides streamlined full-stack web app development.
990 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Ganesh Patapati 1,745 Reputation points Microsoft Vendor
    2024-11-12T18:25:30.4033333+00:00

    Hi LYC,

    Greetings!

    Welcome to the Microsoft Q&A Platform. Thank you for reaching out & I hope you are doing well.

    It sounds like you're experiencing issues with configuring custom domains for your Azure Front Door setup, specifically with the non-www domain (my_domain.co.kr) for your product server.

    1. DNS Configuration: The DNS_PROBE_FINISHED_NXDOMAIN error indicates that the DNS resolution for your non-www domain is failing. This could be due to:
      • The DNS records for my_domain.co.kr not being set up correctly or not propagated yet.
      • The TXT records required for domain validation might not be correctly configured or missing.

    Check DNS Records:

    • Use a DNS lookup tool (like dig web) to verify that the DNS records for my_domain.co.kr are correctly set up. You should see the appropriate A or CNAME records pointing to your Azure Front Door.
    • Ensure that you have added the necessary TXT records for domain verification for the product server.

    Custom Domain Verification: Azure requires verification of custom domains through TXT records. If the product server doesn't show "Add a CNAME, ALIAS or A record," it may indicate that the domain verification has not been completed successfully.

    Verify Domain in Azure:

    • Go to the Azure portal and navigate to your Front Door instance.
    • Under the "Custom domains" tab, ensure that both www.my_domain.co.kr and my_domain.co.kr are listed and verified.
    • If the product server's custom domain is not verified, follow the instructions to add the TXT record again and wait for it to propagate.
    1. Propagation Delay: DNS changes can take time to propagate. If the changes were made recently, it might take some time for the DNS records to become active.

    Setting up an apex domain is a common scenario to configure once your domain name is set up. Creating an apex domain is achieved by configuring an ALIAS or ANAME record or through CNAME flattening. Some domain registrars like GoDaddy and Squarespace (formerly Google) don't support these DNS records. If your domain registrar doesn't support all the DNS records you need, consider using Azure DNS to configure your domain.

    The following are terms you might encounter as you set up a custom domain.

    • Apex or root domains: Given the domain www.example.com, the www prefix is known as the subdomain, while the remaining segment of example.com is referred to as the apex domain.
    • Domain registrar: A registrar verifies the availability of a domain sells the rights to purchase a domain name.
    • DNS zone: A Domain Name System (DNS) zone hosts the DNS records associated to a specific domain. There are various records available which direct traffic for different purposes. For example, the domain example.com may contain several DNS records. One record handles traffic for mail.example.com (for a mail server), and another www.example.com (for a website).
    • DNS hosting: A DNS host maintains DNS servers that resolve a domain name to a specific IP address.
    • Name server: A name server is responsible for storing the DNS records for a domain.

    Hope this clarifies,

    If you are still facing any further issues, please don't hesitate to reach out to us. We are happy to assist you.

    Please don’t forget to close the thread by clicking "Accept the answer" wherever the information provided helps you, as this can be beneficial to other community members.

    Looking forward to your response and appreciate your time on this.

    Regards,

    Ganesh


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.