Azure / Azure/Azure-DataFactory

how to use PrePostDeploymentScript.Ver2.ps1 within CICD ADF

Open
#501 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
PowerShell
Stars
529
Forks
623
PR merge metrics
No merged PRs in 30d

Description

How am i meant to use this ps1 script in the deployment. the usual build process somehow drops PrePostDeploymentScript.ps1 into the application artifacts folder. however this file isnt copied into the folder the same way?

am i meant to manually take a copy of this version and create a copy task to copy the file to the artifacts folder?

```

- task: AzurePowerShell@5
displayName: 'Start triggers and cleanup'
inputs:
azureSubscription: '${{parameters.azureSubscriptionSPN}}'
pwsh: true
azurePowerShellVersion: LatestVersion
scriptType: filePath
scriptPath: '$(Pipeline.Workspace)/datafactory/application/PrePostDeploymentScript.Ver2.ps1'
scriptArguments:
-armTemplate $(Pipeline.Workspace)/datafactory/application/arm-parameters-${{lower(parameters.Stage)}}.json
-ResourceGroupName ${{parameters.resourceGroupName}}
-DataFactoryName ${{parameters.dataFactoryName}}
-predeployment $false
-deleteDeployment $true
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.