[英]How can i pass an azure cli variable to Azure Devops variables?
I have written an Azure cli task in Azure Devops as below我在 Azure Devops 中编写了一个 Azure cli 任务,如下所示
$vnetid = $(az network vnet show -n $vnet -g $(rg) --query id --output tsv) $vnetid = $(az network vnet show -n $vnet -g $(rg) --query id --output tsv)
I want to output the $vnetid to the Azure Devops Variables so it can be used in another task how can i do this?我想要 output 的 $vnetid 到 Azure Devops 变量,所以它可以用于另一个任务我该怎么做?
I guess you can simply do我想你可以简单地做
Write-Output("##vso[task.setvariable variable=vnetid;]$$vnetid")
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.