【问题标题】:TerraformApply.jsonOutputVariablesPath : The term 'TerraformApply.jsonOutputVariablesPath' is not recognized as the name of a cmdlet, functionTerraformApply.jsonOutputVariablesPath :术语 \'TerraformApply.jsonOutputVariablesPath\' 未被识别为 cmdlet、函数的名称
【发布时间】:2022-08-19 14:00:17
【问题描述】:

TerraformApply.jsonOutputVariablesPath :术语 \'TerraformApply.jsonOutputVariablesPath\' 未被识别为 cmdlet、函数、脚本文件或可运行的程序。检查拼写 名称,或者如果包含路径,请验证路径是否正确并重试。 我正在尝试通过 terraform 在 azure devops 中输出变量,但每次我运行管道时 有时候是这样的 。 PS我正在使用自托管代理

  • 请提供足够的代码,以便其他人可以更好地理解或重现该问题。
  • 脚本:| $json = 获取内容 $(TerraformApply.jsonOutputVariablesPath) |外串 | ConvertFrom-Json; foreach($prop in $json.psobject.properties) { Write-Host(\"##vso[task.setvariable variable=$($prop.Name);]$($prop.Value.value)\") }这是我在我的 azure devops yaml 管道中使用的 powershell 命令...................... .,........

标签: azure-devops terraform


【解决方案1】:

任务的版本有问题。 我假设您使用的是 V1。 尝试使用 V3 进行申请。

我已经打开了一个问题 https://github.com/microsoft/azure-pipelines-terraform/issues/83

编辑:我搞砸了版本。

【讨论】:

    猜你喜欢
    • 2021-08-19
    • 1970-01-01
    • 1970-01-01
    • 2021-12-22
    • 2019-10-12
    • 2017-12-11
    • 2021-12-09
    • 2020-02-25
    • 2020-04-17
    相关资源
    最近更新 更多