Skip to content

Commit b847261

Browse files
Merge pull request #213058 from davidsmatlak/ds-ghi-99157
Updates cli commands for managed apps service catalog quickstart
2 parents 4a6b8f8 + f831251 commit b847261

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

articles/azure-resource-manager/managed-applications/publish-service-catalog-app.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: davidsmatlak
55
ms.author: davidsmatlak
66
ms.topic: quickstart
77
ms.custom: subject-armqs, devx-track-azurecli, devx-track-azurepowershell, subject-rbac-steps, mode-api, mode-arm
8-
ms.date: 08/22/2022
8+
ms.date: 09/29/2022
99
---
1010

1111
# Quickstart: Create and publish an Azure Managed Application definition
@@ -185,21 +185,28 @@ az storage account create \
185185
--location eastus \
186186
--sku Standard_LRS \
187187
--kind StorageV2
188+
```
189+
190+
After you create the storage account, add the role assignment _Storage Blob Data Contributor_ to the storage account scope. Assign access to your Azure Active Directory user account. Depending on your access level in Azure, you might need other permissions assigned by your administrator. For more information, see [Assign an Azure role for access to blob data](../../storage/blobs/assign-azure-role-data-access.md).
191+
192+
After you add the role to the storage account, it takes a few minutes to become active in Azure. You can then use the parameter `--auth-mode login` in the commands to create the container and upload the file.
188193

194+
```azurecli-interactive
189195
az storage container create \
190196
--account-name demostorageaccount \
191197
--name appcontainer \
198+
--auth-mode login \
192199
--public-access blob
193200
194201
az storage blob upload \
195202
--account-name demostorageaccount \
196203
--container-name appcontainer \
204+
--auth-mode login \
197205
--name "app.zip" \
198206
--file "./app.zip"
199-
200207
```
201208

202-
When you run the Azure CLI command to create the container, you might see a warning message about credentials, but the command will be successful. The reason is because although you own the storage account you assign roles like _Storage Blob Data Contributor_ to the storage account scope. For more information, see [Assign an Azure role for access to blob data](../../storage/blobs/assign-azure-role-data-access.md). After you add a role, it takes a few minutes to become active in Azure. You can then append the command with `--auth-mode login` and resolve the warning message.
209+
For more information about storage authentication, see [Choose how to authorize access to blob data with Azure CLI](../../storage/blobs/authorize-data-operations-cli.md).
203210

204211
---
205212

@@ -209,9 +216,9 @@ In this section you'll get identity information from Azure Active Directory, cre
209216

210217
### Create an Azure Active Directory user group or application
211218

212-
The next step is to select a user group, user, or application for managing the resources for the customer. This identity has permissions on the managed resource group according to the role that is assigned. The role can be any Azure built-in role like Owner or Contributor. To create a new Active Directory user group, see [Create a group and add members in Azure Active Directory](../../active-directory/fundamentals/active-directory-groups-create-azure-portal.md).
219+
The next step is to select a user group, user, or application for managing the resources for the customer. This identity has permissions on the managed resource group according to the role that's assigned. The role can be any Azure built-in role like Owner or Contributor. To create a new Active Directory user group, see [Create a group and add members in Azure Active Directory](../../active-directory/fundamentals/active-directory-groups-create-azure-portal.md).
213220

214-
You need the object ID of the user group to use for managing the resources.
221+
This example uses a user group, so you need the object ID of the user group to use for managing the resources. Replace the placeholder `mygroup` with your group's name.
215222

216223
# [PowerShell](#tab/azure-powershell)
217224

@@ -267,6 +274,8 @@ az group create --name appDefinitionGroup --location westcentralus
267274

268275
Create the managed application definition resource. In the `Name` parameter, replace the placeholder `demostorageaccount` with your unique storage account name.
269276

277+
The `blob` command that's run from Azure PowerShell or Azure CLI creates a variable that's used to get the URL for the package _.zip_ file. That variable is used in the command that creates the managed application definition.
278+
270279
# [PowerShell](#tab/azure-powershell)
271280

272281
```azurepowershell-interactive
@@ -289,6 +298,7 @@ New-AzManagedApplicationDefinition `
289298
blob=$(az storage blob url \
290299
--account-name demostorageaccount \
291300
--container-name appcontainer \
301+
--auth-mode login \
292302
--name app.zip --output tsv)
293303
294304
az managedapp definition create \

0 commit comments

Comments
 (0)