【发布时间】:2022-09-25 00:50:03
【问题描述】:
- task: Docker@2
displayName: Build an image
inputs:
command: build
repository: weather-update-project
dockerfile: \'**/Dockerfile\'
buildContext: \'$(Build.SourcesDirectory)\'
tags: \'latest\'
- task: ECRPushImage@1
inputs:
awsCredentials: \'weather\'
regionName: us-west-2
imageSource: \'imagename\'
sourceImageName: \'weather-update-project\'
sourceImageTag: \'latest\'
pushTag: \'latest\'
repositoryName: \'weather-update-project\'
我正在构建一个图像,然后尝试将该图像推送到 ECR。当它到达 ECR 推送映像任务时,它尝试推送几次,然后给我错误“进程 \'/usr/bin/docker\' failed with exit code 1\”,就是这样.我的日志中没有其他关于通常存在的错误的信息。可能发生什么?我的 ECR 是公开的,我的所有凭据都是正确的。这是我在 Azure DevOps 中用于 docker build 和 ecrpushimage 任务的 YAML 代码
包含我的 dockerfile 的存储库名称是 \'weather-update-project\' 并且我的 ECR 存储库也有名称 \'weather-update-project\'
标签: docker azure-devops yaml azure-pipelines amazon-ecr