Azure Heml Init任务无法找到kubectl

整夜,由于引入了新的Helm Install任务或3.0 Helm版本,我们所有的构建和发布管道均失败了。我们通过在预览中使用* 1版本来修复Helm的安装,并安装了最新的工作头盔2.16.0。之后,我们的任务Heml Init失败了,因为它找不到kubectl。昨天一切正常。这在我们所有的版本和发行版中都在发生。由于某种原因,它尝试在其中找到kubectl的目录为空。整个晚上有什么变化吗?

日志:

2019-11-14T10:22:21.1487212Z ##[debug]Kubeconfig file path: C:\agent\_work\_temp\helmTask\1573726941144\config
2019-11-14T10:22:21.1494250Z ##[debug]which 'kubectl'
2019-11-14T10:22:21.1574073Z ##[debug]not found
2019-11-14T10:22:21.1576552Z ##[debug]task result: Failed
2019-11-14T10:22:21.1634103Z ##[error]Error: Unable to locate executable file: 'kubectl'. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.
2019-11-14T10:22:21.1641140Z ##[debug]Processed: ##vso[task.issue type=error;]Error: Unable to locate executable file: 'kubectl'. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.
2019-11-14T10:22:21.1642296Z ##[debug]Processed: ##vso[task.complete result=Failed;]Error: Unable to locate executable file: 'kubectl'. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.```

gyz111427 回答:Azure Heml Init任务无法找到kubectl

解决方案是将checkLatestHemlVersion添加为false:

- task: HelmInstaller@0
   displayName: 'Install Helm 2.16.1'
   inputs:
     helmVersion: 2.16.1
     checkLatestHelmVersion: false
本文链接:https://www.f2er.com/3102641.html

大家都在问