Specifying DNS Settings in a Service Configuration File

DNS elements

A service configuration file may contain a DnsServers element with a list of IPv4 addresses for the Domain Name System (DNS) servers that the service will use. Settings in the service configuration file take precedence over settings in the network configuration file. For more information, see Azure Service Configuration Schema (.cscfg File).

NetworkConfiguration element

  <DnsServers>
    <DnsServer name="ID1" IPAddress="IPAddress1" />
    <DnsServer name="ID2" IPAddress="IPAddress2" />
    <DnsServer name="ID3" IPAddress="IPAddress3" />
  </DnsServers>

Warning

The name attribute in the DnsServer element is used only as a reference name. It does not represent the host name for the DNS server. Each DnsServer attribute value must be unique across the entire Microsoft Azure subscription.

See Also

Azure Service Configuration Schema (.cscfg)

Azure Virtual Network Configuration Schema

Configure a Virtual Network Using Network Configuration Files

About Virtual Network settings in the Management Portal