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
- **Display name**: Enter *Download ApplicationPackage to Agent*.
437
+
- **Artifact name**: Enter *hpc-application*.
438
+
- **Destination directory**: Enter *$(System.DefaultWorkingDirectory)*.
439
439
440
440
1. Create a Storage account to store your ARM templates. You could use an existing storage account, but to support this self-contained example and isolation of content, make a dedicated storage account.
441
441
442
442
Select the **ARM Template deployment: Resource Group scope** task, and set the following properties:
443
-
- **Display name:** *Deploy storage account for ARM templates*
443
+
- **Display name:** Enter *Deploy storage account for ARM templates*.
444
444
- **Azure Resource Manager connection**: Select the service connection to use.
445
445
- **Subscription:** Select the appropriate Azure subscription.
446
446
- **Action**: Select **Create or update resource group**.
- **Resource group**: Enter *$(resourceGroupName)*.
448
+
- **Location**: Enter *$(location)*.
449
+
- **Template**: Enter *$(System.ArtifactsDirectory)/\<AzureRepoArtifactSourceAlias>/arm-templates/storageAccount.json*.
450
+
- **Override template parameters**: Enter *-accountName $(storageAccountName)*.
451
451
452
452
1. Upload the artifacts from source control into the storage account. As part of this Azure Pipelines task, the Storage account container URI and SAS token are output to a variable in Azure Pipelines, so they can be reused throughout this agent phase.
453
453
454
454
Select the **Azure File Copy** task, and set the following properties:
- **Source:** Enter *$(System.ArtifactsDirectory)/\<AzureRepoArtifactSourceAlias>/arm-templates/*.
457
457
- **Azure Subscription:** Select the appropriate Azure subscription.
458
-
- **Destination Type**: *Azure Blob*
459
-
- **RM Storage Account**: *$(storageAccountName)*
460
-
- **Container Name**: *templates*
461
-
- **Reference name** under **Output Variables**: *ffmpeg*
458
+
- **Destination Type**: Select **Azure Blob**.
459
+
- **RM Storage Account**: Enter *$(storageAccountName)*.
460
+
- **Container Name**: Enter *templates*.
461
+
- **Reference name**: Expand **Output Variables**, then enter *ffmpeg*.
462
462
463
463
>[!NOTE]
464
-
>If this step fails, make sure your Azure DevOps organization has **Storage Blob Contributor** role in the storage account created.
464
+
>If this step fails, make sure your Azure DevOps organization has **Storage Blob Contributor** role in the storage account.
465
465
466
466
1. Deploy the orchestrator ARM template to create the Batch account and pool. This template includes parameters for the Storage account container URI and SAS token. The variables required in the ARM template are held in the variables section of the release definition and were set from the AzureBlob File Copy task.
467
467
468
468
Select the **ARM Template deployment: Resource Group scope** task, and set the following properties:
469
-
- **Display name:** *Deploy Azure Batch*
469
+
- **Display name:** Enter *Deploy Azure Batch*.
470
470
- **Azure Resource Manager connection:** Select the appropriate Azure subscription.
471
471
- **Subscription:** Select the appropriate Azure subscription.
472
472
- **Action**: Select **Create or update resource group**.
473
-
- **Resource group**: *$(resourceGroupName)*
474
-
- **Location**: *$(location)*
473
+
- **Resource group**: Enter *$(resourceGroupName)*.
474
+
- **Location**: Enter *$(location)*.
475
475
- **Template location**: Select **URL of the file**.
A common practice is to use Azure Key Vault tasks. If the service principal connected to your Azure subscription has an appropriate access policy set, it can download secrets from Key Vault and be used as a variable in your pipeline. The name of the secret is set with the associated value. For example, you could reference a secret of **sshPassword** with *$(sshPassword)* in the release definition.
480
480
481
481
1. Call Azure CLI to create an application in Azure Batch and upload associated packages.
482
482
483
483
Select the **Azure CLI** task, and set the following properties:
484
-
- **Display name:** *Create application in Azure Batch account*
484
+
- **Display name:** Enter *Create application in Azure Batch account*.
485
485
- **Azure Resource Manager connection:** Select the appropriate Azure subscription.
> The version number of the application package is set to a variable. The variable allows overwriting previous versions of the package and lets you manually control the package version pushed to Azure Batch.
0 commit comments