我定义了两个yaml模板,一个用于创建docker注册中心服务连接,另一个用于通过容器作业部署一些内容。第二个模板使用在第一个模板中部署的docker注册表连接。当我分别运行两个模板时,两个阶段都成功了,但当我在一个azure-pipelines.yaml中运行它们时,它失败了:
There was a resource authorization issue: "The pipeline is not valid. A service connection with name shared-stratus-acr-endpoint could not be found. The service connection does not exist or has not been authorized for use. For authorization details, refer to https://aka.ms/yamlauthz."在这种情况下,我们能提供像dependsOn或condition这样的方法吗?
发布于 2020-02-10 11:07:29
很可能在创建单个模板\管道时,您只授权了它们的服务连接。工作流程不是超级友好的。
如果您尝试为该服务连接显式地授权失败的管道,该怎么办?请参阅docs here

您还可以根据您的安全需求,仅授权所有管道的服务连接。
https://stackoverflow.com/questions/60131873
复制相似问题