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
Copy file name to clipboardExpand all lines: articles/spring-apps/how-to-custom-domain.md
+21-15Lines changed: 21 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -26,7 +26,7 @@ Certificates encrypt web traffic. These TLS/SSL certificates can be stored in Az
26
26
27
27
- An Azure subscription. If you don't have a subscription, create a [free account](https://azure.microsoft.com/free/) before you begin.
28
28
- (Optional) [Azure CLI](/cli/azure/install-azure-cli) version 2.45.0 or higher. Use the following command to install the Azure Spring Apps extension: `az extension add --name spring`
29
-
- An application deployed to Azure Spring Apps (see [Quickstart: Launch an existing application in Azure Spring Apps using the Azure portal](./quickstart.md), or use an existing app).
29
+
- An application deployed to Azure Spring Apps (see [Quickstart: Launch an existing application in Azure Spring Apps using the Azure portal](./quickstart.md), or use an existing app). If your application is deployed using the Basic plan, be sure to upgrade to the Standard plan.
30
30
- A domain name with access to the DNS registry for a domain provider, such as GoDaddy.
31
31
- A private certificate (that is, your self-signed certificate) from a third-party provider. The certificate must match the domain.
32
32
- A deployed instance of Azure Key Vault. For more information, see [About Azure Key Vault](../key-vault/general/overview.md).
@@ -118,7 +118,7 @@ Use the following steps to upload your certificate to key vault:
118
118
1. Go to your key vault instance.
119
119
1. In the navigation pane, select **Certificates**.
120
120
1. On the upper menu, select **Generate/import**.
121
-
1.In the **Create a certificate**dialog under**Method of certificate creation**, select `Import`.
121
+
1.On the **Create a certificate**page, select**Import** for **Method of Certificate Creation**, and then provide a value for **Certificate Name**.
122
122
1. Under **Upload Certificate File**, navigate to certificate location and select it.
123
123
1. Under **Password**, if you're uploading a password protected certificate file, provide that password here. Otherwise, leave it blank. Once the certificate file is successfully imported, key vault removes that password.
124
124
1. Select **Create**.
@@ -131,10 +131,10 @@ Use the following command to import a certificate:
131
131
132
132
```azurecli
133
133
az keyvault certificate import \
134
-
--file <path-to-pfx-file> \
134
+
--file <path-to-pfx-or-pem-file> \
135
135
--name <certificate-name> \
136
136
--vault-name <key-vault-name> \
137
-
--password <export-password>
137
+
--password <password-if-needed>
138
138
```
139
139
140
140
---
@@ -188,6 +188,12 @@ az keyvault set-policy \
188
188
189
189
:::image type="content" source="./media/how-to-custom-domain/import-certificate.png" alt-text="Screenshot of the Azure portal showing the TLS/SSL settings page for an Azure Spring Apps instance, with the Import key vault certificate button highlighted." lightbox="./media/how-to-custom-domain/import-certificate.png":::
190
190
191
+
1. On the **Select certificate from Azure** page, select the **Subscription**, **Key Vault**, and **Certificate** from the drop-down options, and then choose **Select**.
192
+
193
+
:::image type="content" source="./media/how-to-custom-domain/select-certificate-from-key-vault.png" alt-text="Screenshot of the Azure portal showing the Select certificate from Azure page." lightbox="./media/how-to-custom-domain/select-certificate-from-key-vault.png":::
194
+
195
+
1. On the opened **Set certificate name** page, enter your certificate name, and then select **Apply**.
196
+
191
197
1. When you have successfully imported your certificate, it displays in the list of **Private Key Certificates**.
192
198
193
199
:::image type="content" source="./media/how-to-custom-domain/key-certificates.png" alt-text="Screenshot of a private key certificate.":::
@@ -230,11 +236,11 @@ You can use a CNAME record to map a custom DNS name to Azure Spring Apps.
230
236
Go to your DNS provider and add a CNAME record to map your domain to the `<service-name>.azuremicroservices.io`. Here, `<service-name>` is the name of your Azure Spring Apps instance. We support wildcard domain and sub domain.
231
237
After you add the CNAME, the DNS records page resembles the following example:
232
238
233
-
:::image type="content" source="./media/how-to-custom-domain/dns-records.png" alt-text="Screenshot of a DNS records page.":::
239
+
:::image type="content" source="./media/how-to-custom-domain/dns-records.png" alt-text="Screenshot of a DNS records page." lightbox="./media/how-to-custom-domain/dns-records.png":::
234
240
235
241
## Map your custom domain to Azure Spring Apps app
236
242
237
-
If you don't have an application in Azure Spring Apps, follow the instructions in [Quickstart: Launch an existing application in Azure Spring Apps using the Azure portal](./quickstart.md).
243
+
If you don't have an application in Azure Spring Apps, follow the instructions in [Quickstart: Deploy your first application to Azure Spring Apps](./quickstart.md).
238
244
239
245
#### [Azure portal](#tab/Azure-portal)
240
246
@@ -272,9 +278,9 @@ Use the following command to show the list of custom domains:
272
278
273
279
```azurecli
274
280
az spring app custom-domain list \
275
-
--resource-group <resource-group-name>
276
-
--service <Azure-Spring-Apps-instance-name>
277
-
--app <app-name> \
281
+
--resource-group <resource-group-name> \
282
+
--service <Azure-Spring-Apps-instance-name> \
283
+
--app <app-name>
278
284
```
279
285
280
286
---
@@ -299,11 +305,11 @@ Use the following command to update a custom domain of the app.
299
305
300
306
```azurecli
301
307
az spring app custom-domain update \
302
-
--resource-group <resource-group-name>
303
-
--service <service-name>
308
+
--resource-group <resource-group-name> \
309
+
--service <service-name> \
304
310
--domain-name <domain-name> \
305
311
--certificate <cert-name> \
306
-
--app <app-name> \
312
+
--app <app-name>
307
313
308
314
```
309
315
@@ -319,9 +325,9 @@ By default, anyone can still access your app using HTTP, but you can redirect al
319
325
320
326
#### [Azure portal](#tab/Azure-portal)
321
327
322
-
In your app page, in the navigation, select **Custom Domain**. Then, set **HTTPS Only**, to `True`.
328
+
In your app page, in the navigation, select **Custom Domain**. Then, set **HTTPS Only** to `Yes`.
323
329
324
-
:::image type="content" source="./media/how-to-custom-domain/enforce-http.png" alt-text="Screenshot of an SSL binding with the Https Only option highlighted.":::
330
+
:::image type="content" source="./media/how-to-custom-domain/enforce-https.png" alt-text="Screenshot of an SSL binding with the Https Only option highlighted.":::
325
331
326
332
#### [Azure CLI](#tab/Azure-CLI)
327
333
@@ -343,4 +349,4 @@ When the operation is complete, navigate to any of the HTTPS URLs that point to
343
349
344
350
-[What is Azure Key Vault?](../key-vault/general/overview.md)
345
351
-[Import a certificate](../key-vault/certificates/certificate-scenarios.md#import-a-certificate)
346
-
-[Launch your Spring Cloud App by using the Azure CLI](./quickstart.md)
0 commit comments