问题
I have created a pipeline which has two parameters at pipeline level. I want to send the values to these parameters using powershell and trigger the pipeline. Any idea how to do it using Powershell.
回答1:
I'll leave a script that you can then modify to your needs:
Login-AzureRmAccount
Select-AzureRmSubscription -Subscription "yourSubId"
$dfname = "youDataFActoryName"
$rgName = "yourResourceGroupName"
$pipe = "pipeName"
$parameters = @{
"param1" = "asdasd"
"param2" = "123456"
}
Invoke-AzureRmDataFactoryV2Pipeline -DataFactoryName $dfname -ResourceGroupName $rgName -PipelineName $pipe -Parameter $parameters
Hope this helped!
来源:https://stackoverflow.com/questions/53756570/how-to-pass-arguments-to-adf-pipeline-using-powershell