You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Azure App Service](overview.md) provides a highly scalable, self-patching web hosting service. This guide shows you how to map an existing custom Domain Name System (DNS) name to App Service. To migrate a live site and its DNS domain name to App Service with no downtime, see [Migrate an active DNS name to Azure App Service](manage-custom-dns-migrate-domain.md).
21
+
[Azure App Service](overview.md) provides a highly scalable, self-patching web hosting service. This guide shows you how to map an existing custom Domain Name System (DNS) name to App Service. To migrate a live site and its DNS domain name to App Service with no downtime, see [Migrate an existing domain to Azure App Service](manage-custom-dns-migrate-domain.md).
22
22
23
-
The DNS record type you need to add with your domain provider depends on the domain you want to add to App Service.
23
+
The DNS record type you need to use depends on the domain you want to add to App Service.
24
24
25
25
| Scenario | Example | Recommended DNS record |
26
26
| - | - | - |
27
-
| Root domain | contoso.com |[A record](https://en.wikipedia.org/wiki/List_of_DNS_record_types#A). Don't use the CNAME record for the root record. (For information, see [RFC 1912, section 2.4](https://datatracker.ietf.org/doc/html/rfc1912#section-2.4).) |
28
-
| Subdomain |www.contoso.com, my.contoso.com |[CNAME record](https://en.wikipedia.org/wiki/CNAME_record). You can map a subdomain to the app's IP address directly with an A record, but it's possible for [the IP address to change](overview-inbound-outbound-ips.md#when-inbound-ip-changes). The CNAME maps to the app's default hostname instead, which is less susceptible to change. |
| Root domain |`contoso.com`|[A record](https://en.wikipedia.org/wiki/List_of_DNS_record_types#A). Don't use the CNAME record for the root domain. (For information, see [RFC 1912, section 2.4](https://datatracker.ietf.org/doc/html/rfc1912#section-2.4).) |
28
+
| Subdomain |`www.contoso.com`, `my.contoso.com`|[CNAME record](https://en.wikipedia.org/wiki/CNAME_record). You can map a subdomain to the app's IP address directly with an A record, but it's possible for [the IP address to change](overview-inbound-outbound-ips.md#when-inbound-ip-changes). The CNAME maps to the app's default hostname instead, which is less susceptible to change. |
> For an end-to-end tutorial that shows you how to configure a `www` subdomain and a managed certificate, see [Tutorial: Secure your Azure App Service app with a custom domain and a managed certificate](tutorial-secure-domain-certificate.md).
32
+
> For an end-to-end tutorial that shows you how to configure a `www` subdomain and a managed certificate, see [Tutorial: Use a custom domain and a managed certificate to secure your app](tutorial-secure-domain-certificate.md).
33
33
34
34
## Prerequisites
35
35
36
-
*[Create an App Service app](./index.yml), or use an app that you created for another tutorial. The web app's [App Service plan](overview-hosting-plans.md) must be a paid tier, not the Free (F1) tier. See [Scale up an app](manage-scale-up.md#scale-up-your-pricing-tier) to update the tier.
37
-
* Make sure you can edit the DNS records for your custom domain. To edit DNS records, you need access to the DNS registry for your domain provider, such as GoDaddy. For example, to add DNS entries for `contoso.com` and `www.contoso.com`, you must be able to configure the DNS settings for the `contoso.com` root domain. Your custom domains must be in a public DNS zone; private DNS zones are not supported.
36
+
* Create an [App Service app](./index.yml), or use an app that you created for another tutorial. The web app's [App Service plan](overview-hosting-plans.md) must be a paid tier, not the Free (F1) tier. To update the tier, see [Scale up your pricing tier](manage-scale-up.md#scale-up-your-pricing-tier).
37
+
* Make sure you can edit the DNS records for your custom domain. To edit DNS records, you need access to the DNS registry for your domain provider, such as GoDaddy. For example, to add DNS entries for `contoso.com` and `www.contoso.com`, you must be able to configure the DNS settings for the `contoso.com` root domain. Your custom domains must be in a public DNS zone; private DNS zones aren't supported.
38
38
* If you don't have a custom domain yet, you can [purchase an App Service domain](manage-custom-dns-buy-domain.md) instead.
39
39
40
40
## Configure a custom domain
41
41
42
42
1. In the [Azure portal](https://portal.azure.com), navigate to your app's management page.
43
-
1. In the left menu for your app, select **Custom domains**.
43
+
44
+
1. In the sidebar menu for your app, under **Settings**, select **Custom domains**.
45
+
44
46
1. Select **Add custom domain**.
45
47
46
48
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/add-custom-domain.png" alt-text="A screenshot showing how to open the Add custom domain dialog." border="true":::
47
49
48
-
1. For **Domain provider**, select **All other domain services** to configure a third-party domain.
50
+
1. For **Domain provider**, select **All other domain services** to configure a non-Microsoft domain.
49
51
50
52
> [!NOTE]
51
-
> To configure an App Service domain, see [Buy a custom domain name for Azure App Service](manage-custom-dns-buy-domain.md).
53
+
> To configure an App Service domain, see [Buy and manage an App Service domain](manage-custom-dns-buy-domain.md).
52
54
53
55
1. For **TLS/SSL certificate**, select **App Service Managed Certificate** if your app is in the Basic tier or higher. If you want to remain in the Shared tier, or if you want to use your own certificate, select **Add certificate later**.
54
56
@@ -92,7 +94,7 @@ Create two records, as described in the following table:
92
94
| A |`@`| The app's IP address shown in the **Add custom domain** dialog. | The domain mapping itself. (`@` typically represents the root domain.) |
93
95
| TXT |`asuid`| The domain verification ID shown in the **Add custom domain** dialog. | For the root domain, App Service accesses the `asuid` TXT record to verify your ownership of the custom domain. |
94
96
95
-

97
+
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/a-record.png" alt-text="Screenshot that shows a DNS records page.":::
96
98
97
99
### [Subdomain (for example, www.contoso.com)](#tab/subdomain)
98
100
@@ -105,7 +107,7 @@ Create two records, as described in the following table:
105
107
|A|`<subdomain>` (for example, `www`)|IP address shown in the **Add custom domain** dialog.| The domain mapping itself. |
106
108
|TXT|`asuid.<subdomain>` (for example, `asuid.www`)|The domain verification ID shown in the **Add custom domain** dialog.| App Service accesses the `asuid.<subdomain>` TXT record to verify your ownership of the custom domain. |
107
109
108
-

110
+
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/a-record-subdomain.png" alt-text="Screenshot that shows a DNS records subdomain page.":::
109
111
110
112
#### With a CNAME record
111
113
@@ -116,7 +118,7 @@ Create two records, as described in the following table:
116
118
| CNAME |`<subdomain>` (for example, `www`) | (See the value in the Azure portal **Overview** page for your app.) | The domain mapping itself. |
117
119
| TXT |`asuid.<subdomain>` (for example, `asuid.www`) | The domain verification ID shown in the **Add custom domain** dialog. | App Service accesses the `asuid.<subdomain>` TXT record to verify your ownership of the custom domain. |
118
120
119
-

121
+
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/cname-record.png" alt-text="Screenshot that shows the portal navigation to an Azure app.":::
120
122
121
123
### [Wildcard (CNAME)](#tab/wildcard)
122
124
@@ -127,7 +129,7 @@ For a wildcard name, like `*` in `*.contoso.com`, create two records, as describ
127
129
| CNAME |`*`| (See the value in the Azure portal **Overview** page for your app.) | The domain mapping itself. |
128
130
| TXT |`asuid`| The domain verification ID shown in the **Add custom domain** dialog. | App Service accesses the `asuid` TXT record to verify your ownership of the custom domain. |
129
131
130
-

132
+
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/cname-record-wildcard.png" alt-text="Screenshot that shows the navigation to an Azure app.":::
131
133
132
134
-----
133
135
@@ -142,22 +144,22 @@ For a wildcard name, like `*` in `*.contoso.com`, create two records, as describ
142
144
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/configure-custom-domain-add.png" alt-text="A screenshot showing the Add button activated after validation." border="true":::
143
145
144
146
> [!NOTE]
145
-
> If you configured the TXT record but not the A or CNAME record, App Service treats the change as a [domain migration](manage-custom-dns-migrate-domain.md) scenario and allows the validation to succeed, but you won't see green check marks next to the records.
147
+
> If you configured the TXT record but not the A or CNAME record, App Service treats the change as a [domain migration](manage-custom-dns-migrate-domain.md) scenario and allows the validation to succeed, but you don't see green check marks next to the records.
146
148
147
149
1. You should see the custom domain added to the list. You might also see a red X and the text **No binding**.
148
150
149
-
If you selected **App Service Managed Certificate** earlier, wait a few minutes for App Service to create the managed certificate for your custom domain. When the process is complete, the red X becomes a green check mark and you see the word **Secured**. If you selected **Add certificate later**, the red X will remain until you [add a private certificate for the domain](configure-ssl-certificate.md) and [configure the binding](configure-ssl-bindings.md).
151
+
If you selected **App Service Managed Certificate** earlier, wait a few minutes for App Service to create the managed certificate for your custom domain. When the process is complete, the red X becomes a green check mark and you see the word **Secured**. If you selected **Add certificate later**, the red X remains until you [add a private certificate for the domain](configure-ssl-certificate.md) and [configure the binding](configure-ssl-bindings.md).
150
152
151
153
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/add-custom-domain-complete.png" alt-text="A screenshot showing the custom domains page with the new secured custom domain." border="true":::
152
154
153
155
> [!NOTE]
154
-
> Unless you configure a certificate binding for your custom domain, any HTTPS request from a browser to the domain will receive an error or warning, depending on the browser.
156
+
> Unless you configure a certificate binding for your custom domain, any HTTPS request from a browser to the domain receives an error or warning, depending on the browser.
155
157
156
158
## Test the DNS resolution
157
159
158
-
Browse to the DNS names that you configured.
160
+
Browse to the domain name that you configured.
159
161
160
-

162
+
:::image type="content" source="./media/app-service-web-tutorial-custom-domain/app-with-custom-dns.png" alt-text="Screenshot that shows navigation to an Azure app.":::
Copy file name to clipboardExpand all lines: articles/app-service/configure-authentication-file-based.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
title: File-Based Configuration of AuthN/AuthZ
3
3
description: Configure authentication and authorization in App Service using a configuration file to enable certain preview capabilities.
4
4
ms.topic: how-to
5
-
ms.date: 07/15/2021
5
+
ms.date: 03/10/2026
6
6
ms.custom: AppServiceIdentity
7
7
author: cephalin
8
8
ms.author: cephalin
@@ -17,7 +17,7 @@ ms.service: azure-app-service
17
17
With [App Service authentication](overview-authentication-authorization.md), the authentication settings can be configured with a file. You may need to use file-based configuration to use certain preview capabilities of App Service authentication / authorization before they're exposed via [Azure Resource Manager](../azure-resource-manager/management/overview.md) APIs.
18
18
19
19
> [!IMPORTANT]
20
-
> Remember that your app payload, and therefore this file, may move between environments, as with [slots](./deploy-staging-slots.md). It is likely you would want a different app registration pinned to each slot, and in these cases, you should continue to use the standard configuration method instead of using the configuration file.
20
+
> Remember that your app payload, and therefore this file, may move between environments, as with [slots](./deploy-staging-slots.md). It's likely you'd want a different app registration pinned to each slot, and in these cases, you should continue to use the standard configuration method instead of using the configuration file.
21
21
22
22
## Enable file-based configuration
23
23
@@ -31,7 +31,7 @@ With [App Service authentication](overview-authentication-authorization.md), the
31
31
> [!NOTE]
32
32
> The format for `platform.configFilePath` varies between platforms. On Windows, both relative and absolute paths are supported. Relative is recommended. For Linux, only absolute paths are supported currently, so the value of the setting should be "/home/site/wwwroot/auth.json" or similar.
33
33
34
-
Once you have made this configuration update, the contents of the file will be used to define the behavior of App Service Authentication / Authorization for that site. If you ever wish to return to Azure Resource Manager configuration, you can do so by removing changing the setting `platform.configFilePath` to null.
34
+
Once you have made this configuration update, the contents of the file will be used to define the behavior of App Service Authentication / Authorization for that site. If you ever wish to return to Azure Resource Manager configuration, you can do so by changing the setting `platform.configFilePath` to null.
0 commit comments