Azure-docs: do we have the documentation for custom dns setting for appservice

Created on 24 Aug 2018  ·  4Comments  ·  Source: MicrosoftDocs/azure-docs

I need to make sure the app service uses my own dns server to resolve the addresses.
Could not locate in the documentation


Document details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri1 app-service-wesvc assigned-to-author doc-enhancement triaged

Most helpful comment

@rifaterdemsahin Please locate the below steps on how to update the DNS settings for your Azure Web App.

  1. Go to the web app->settings->Application Settings-> App Settings section
  2. Add the following: (WEBSITE_NODE_DEFAULT) should already be there.
    a. WEBSITE_DNS_SERVER with value having the IP address of the primary DNS server.
    b. WEBSITE_ALT_DNS_SERVER (optional), with value having the IP address of a second DNS server.
  3. Then save the settings & restart webapp in portal.
  4. Double check the web app can actually connect to the DNS server:
    a. In kudu console, run:
    Nameresolver.exe [hostname-to-lookup] [dns-server-to-use]
    First argument should be the hostname you are trying to look up, second argument is one of the DNS servers from step 1)
    If this times out, there is an issue with how your DNS servers are configured (firewalls, etc.)

@cephalin Is this something that you would consider incorporating into the doc?

All 4 comments

Hi @rifaterdemsahin Thank you for your feedback! We will investigate and get back to you with our findings.

@rifaterdemsahin Please locate the below steps on how to update the DNS settings for your Azure Web App.

  1. Go to the web app->settings->Application Settings-> App Settings section
  2. Add the following: (WEBSITE_NODE_DEFAULT) should already be there.
    a. WEBSITE_DNS_SERVER with value having the IP address of the primary DNS server.
    b. WEBSITE_ALT_DNS_SERVER (optional), with value having the IP address of a second DNS server.
  3. Then save the settings & restart webapp in portal.
  4. Double check the web app can actually connect to the DNS server:
    a. In kudu console, run:
    Nameresolver.exe [hostname-to-lookup] [dns-server-to-use]
    First argument should be the hostname you are trying to look up, second argument is one of the DNS servers from step 1)
    If this times out, there is an issue with how your DNS servers are configured (firewalls, etc.)

@cephalin Is this something that you would consider incorporating into the doc?

This also works though not using an App Service Environment (ASE).

I needed to use an On-Premises DNS Server through a Site-to-Site connection where the App Service was connected to the VNet, and this did the trick for us! Thanks for the post 👍

Sorry for the delay. Opened https://github.com/projectkudu/kudu/issues/3060 to add the information to https://github.com/projectkudu/kudu/wiki/Configurable-settings. The information isn't appropriate here because it doesn't have anything to do with mapping custom domains.

please-close

Was this page helpful?
0 / 5 - 0 ratings