简体   繁体   English

使用 AWS ECR 的 Docker 登录问题

[英]Issue with Docker Login with AWS ECR

I'm following an aws tutorial to deploy a simple application using containers on aws.我正在按照 aws 教程使用 aws 上的容器部署一个简单的应用程序。 I'm trying to connect to AWS's ECR using docker and i get a warning message which doesnt allow me to login.我正在尝试使用 docker 连接到 AWS 的 ECR,但收到一条不允许我登录的警告消息。

I'm brand new to the world of docker, containers and aws.我是 docker、容器和 aws 的新手。 I was going through aws tutorials to deploy a simple nodejs application using docker containers into aws per the following instructions:我正在阅读 aws 教程,按照以下说明使用 docker 容器将一个简单的 nodejs 应用程序部署到 aws 中:

https://aws.amazon.com/getting-started/projects/break-monolith-app-microservices-ecs-docker-ec2/module-one/ https://aws.amazon.com/getting-started/projects/break-monolith-app-microservices-ecs-docker-ec2/module-one/

Per instructions, i've installed docker, AWS CLI and created a AWS ECR for docker to access.根据说明,我已经安装了 docker、AWS CLI 并创建了一个 AWS ECR 供 docker 访问。 I've basically got till the following step: Step 4 Build and Push the docker image - Point 2 - getting login我基本上已经到了以下步骤:第 4 步构建并推送 docker 映像 - 第 2 点 - 登录

As per point 2, i copy pasted the login details (docker login -u AWS -p ) and ran it and i got the following warning message which isnt allowing me to login or push the docker image to ECR.根据第 2 点,我复制粘贴了登录详细信息(docker login -u AWS -p )并运行它,我收到以下警告消息,该消息不允许我登录或将 docker 映像推送到 ECR。 I tried to research online a lot on what to change.我试图在网上大量研究要改变什么。 There are lots of articles mentioning the issue but no clear direction as to what exactly to do.有很多文章提到了这个问题,但没有明确说明到底要做什么。 I'm not exactly sure where in the command i should use --password-stdin.我不确定应该在命令中的哪个位置使用 --password-stdin。 I've also tried what was provided in the following link [ Docker: Using --password via the CLI is insecure.我还尝试了以下链接中提供的内容 [ Docker:通过 CLI 使用 --password 是不安全的。 Use --password-stdin but that didnt work either 使用 --password-stdin但这也不起作用

Expected result: Login succeeded预期结果:登录成功

Actual result: WARNING!实际结果:警告! Using --password via the CLI is insecure.通过 CLI 使用 --password 是不安全的。 Use --password-stdin.使用 --password-stdin。

the warning is fine.警告很好。 have you verified whether the docker push/pull is working ?您是否已验证 docker push/pull 是否正常工作?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM