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
@@ -22,18 +22,27 @@ The [Azure CLI](/cli/azure) is a set of commands used to create and manage Azure
22
22
23
23
- This quickstart assumes that you already have at least an App Service running on Azure. If you don't have an App Service, [create one](../app-service/quickstart-dotnetcore.md).
24
24
25
-
## View supported target service types
25
+
## Initial set-up
26
26
27
-
Use the Azure CLI [az webapp connection list](/cli/azure/webapp/connection#az-webapp-connection-list) command to get a list of supported target services for App Service.
27
+
1. If you're using Service Connector for the first time, start by running the command [az provider register](/cli/azure/provider#az-provider-register)to register the Service Connector resource provider.
28
28
29
-
```azurecli-interactive
30
-
az provider register -n Microsoft.ServiceLinker
31
-
az webapp connection list-support-types --output table
32
-
```
29
+
```azurecli
30
+
az provider register -n Microsoft.ServiceLinker
31
+
```
32
+
33
+
> [!TIP]
34
+
> You can check if the resource provider has already been registered by running the command `az provider show -n "Microsoft.ServiceLinker" --query registrationState`. If the output is `Registered`, then Service Connector has already been registered.
35
+
36
+
37
+
1. Optionally, use the Azure CLI [az webapp connection list-support-types](/cli/azure/webapp/connection#az-webapp-connection-list-support-types) command to get a list of supported target services for App Service.
33
38
39
+
```azurecli
40
+
az webapp connection list-support-types --output table
41
+
```
42
+
34
43
## Create a service connection
35
44
36
-
#### [Using Access Key](#tab/Using-access-key)
45
+
#### [Using an access key](#tab/Using-access-key)
37
46
38
47
Use the Azure CLI [az webapp connection create](/cli/azure/webapp/connection/create) command to create a service connection to an Azure Blob Storage with an access key, providing the following information:
39
48
@@ -42,14 +51,14 @@ Use the Azure CLI [az webapp connection create](/cli/azure/webapp/connection/cre
42
51
- **Target service resource group name:** the resource group name of the Blob Storage.
43
52
- **Storage account name:** the account name of your Blob Storage.
44
53
45
-
```azurecli-interactive
54
+
```azurecli
46
55
az webapp connection create storage-blob --secret
47
56
```
48
57
49
58
> [!NOTE]
50
59
> If you don't have a Blob Storage, you can run `az webapp connection create storage-blob --new --secret` to provision a new one and directly get connected to your app service.
#### [Using a managed identity](#tab/Using-Managed-Identity)
53
62
54
63
> [!IMPORTANT]
55
64
> Using Managed Identity requires you have the permission to [Azure AD role assignment](../active-directory/managed-identities-azure-resources/howto-assign-access-portal.md). If you don't have the permission, your connection creation would fail. You can ask your subscription owner for the permission or using access key to create the connection.
@@ -61,7 +70,7 @@ Use the Azure CLI [az webapp connection](/cli/azure/webapp/connection) command t
61
70
-**Target service resource group name:** the resource group name of the Blob Storage.
62
71
-**Storage account name:** the account name of your Blob Storage.
63
72
64
-
```azurecli-interactive
73
+
```azurecli
65
74
az webapp connection create storage-blob --system-identity
66
75
```
67
76
@@ -77,7 +86,7 @@ Use the Azure CLI [az webapp connection](/cli/azure/webapp/connection) command t
77
86
-**Source compute service resource group name:** the resource group name of the App Service.
78
87
-**App Service name:** the name of your App Service that connects to the target service.
79
88
80
-
```azurecli-interactive
89
+
```azurecli
81
90
az webapp connection list -g "<your-app-service-resource-group>" -n "<your-app-service-name>" --output table
Copy file name to clipboardExpand all lines: articles/service-connector/quickstart-cli-container-apps.md
+12-9Lines changed: 12 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ author: maud-lv
5
5
ms.author: malev
6
6
ms.service: service-connector
7
7
ms.topic: quickstart
8
-
ms.date: 08/09/2022
8
+
ms.date: 04/13/2023
9
9
ms.devlang: azurecli
10
10
ms.custom: devx-track-azurecli
11
11
---
@@ -30,17 +30,20 @@ This quickstart shows you how to connect Azure Container Apps to other Cloud res
30
30
31
31
- The Container Apps extension must be installed in the Azure CLI or the Cloud Shell. To install it, run `az extension add --name containerapp`.
32
32
33
-
## Prepare to create a connection
33
+
## Initial set-up
34
34
35
-
1.Run the command [az provider register](/cli/azure/provider#az-provider-register) to start using Service Connector.
35
+
1.If you're using Service Connector for the first time, start by running the command [az provider register](/cli/azure/provider#az-provider-register) to register the Service Connector resource provider.
36
36
37
-
```azurecli-interactive
37
+
```azurecli
38
38
az provider register -n Microsoft.ServiceLinker
39
39
```
40
40
41
-
1. Run the command `az containerapp connection` to get a list of supported target services for Container Apps.
41
+
> [!TIP]
42
+
> You can check if the resource provider has already been registered by running the command `az provider show -n "Microsoft.ServiceLinker" --query registrationState`. If the output is `Registered`, then Service Connector has already been registered.
42
43
43
-
```azurecli-interactive
44
+
1. Optionally, run the command [az containerapp connection list-support-types](/cli/azure/containerapp/connection#az-containerapp-connection-list-support-types) to get a list of supported target services for Container Apps.
45
+
46
+
```azurecli
44
47
az containerapp connection list-support-types --output table
45
48
```
46
49
@@ -52,7 +55,7 @@ You can create a connection using an access key or a managed identity.
52
55
53
56
1. Run the `az containerapp connection create` command to create a service connection between Container Apps and Azure Blob Storage with an access key.
54
57
55
-
```azurecli-interactive
58
+
```azurecli
56
59
az containerapp connection create storage-blob --secret
57
60
```
58
61
@@ -76,7 +79,7 @@ You can create a connection using an access key or a managed identity.
76
79
77
80
1. Run the `az containerapp connection create` command to create a service connection from Container Apps to a Blob Storage with a system-assigned managed identity.
78
81
79
-
```azurecli-interactive
82
+
```azurecli
80
83
az containerapp connection create storage-blob --system-identity
81
84
```
82
85
@@ -99,7 +102,7 @@ You can create a connection using an access key or a managed identity.
99
102
100
103
Use the Azure CLI command `az containerapp connection list` to list all your container app's provisioned connections. Replace the placeholders `<container-app-resource-group>` and `<container-app-name>` from the command below with the resource group and name of your container app. You can also remove the `--output table` option to view more information about your connections.
101
104
102
-
```azurecli-interactive
105
+
```azurecli
103
106
az containerapp connection list -g "<container-app-resource-group>" --name "<container-app-name>" --output table
@@ -29,17 +29,21 @@ Service Connector lets you quickly connect compute services to cloud services, w
29
29
30
30
- The Azure Spring Apps extension must be installed in the Azure CLI or the Cloud Shell. To install it, run `az extension add --name spring`.
31
31
32
-
## Prepare to create a connection
32
+
## Initial set up
33
33
34
34
1. If you're using Service Connector for the first time, start by running the command [az provider register](/cli/azure/provider#az-provider-register) to register the Service Connector resource provider.
35
35
36
-
```azurecli-interactive
36
+
```azurecli
37
37
az provider register -n Microsoft.ServiceLinker
38
38
```
39
39
40
-
1. Run the command `az spring connection` to get a list of supported target services for Azure Spring Apps.
40
+
> [!TIP]
41
+
> You can check if the resource provider has already been registered by running the command `az provider show -n "Microsoft.ServiceLinker" --query registrationState`. If the output is `Registered`, then Service Connector has already been registered.
41
42
42
-
```azurecli-interactive
43
+
44
+
1. Optionally, run the command [az spring connection list-support-types](/cli/azure/spring/connection#az-spring-connection-list-support-types) to get a list of supported target services for Azure Spring Apps.
45
+
46
+
```azurecli
43
47
az spring connection list-support-types --output table
44
48
```
45
49
@@ -54,7 +58,7 @@ You can create a connection from Azure Spring Apps using an access key or a mana
54
58
55
59
1. Run the `az spring connection create` command to create a service connection between Azure Spring Apps and an Azure Blob Storage with an access key.
0 commit comments