Docker: error using docker-compose up on the official getting started tutorial

标签 docker docker-compose

我是 docker 新手,我正在尝试学习这个简单的“入门”教程 https://docs.docker.com/compose/gettingstarted/使用新安装的 docker(适用于 Windows 10)从此处下载:https://hub.docker.com/editions/community/docker-ce-desktop-windows/ .

在本教程的第 4 步,我收到此错误:

PS D:\composetest> docker-compose up
Building web
Traceback (most recent call last):
  File "site-packages\docker\credentials\store.py", line 80, in _execute
  File "subprocess.py", line 395, in check_output
  File "subprocess.py", line 487, in run
subprocess.CalledProcessError: Command '['C:\\Program Files\\Docker\\Docker\\resources\\bin\\docker-credential-desktop.EXE', 'list']' returned non-zero exit status 1.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "docker-compose", line 6, in <module>
  File "compose\cli\main.py", line 72, in main
  File "compose\cli\main.py", line 128, in perform_command
  File "compose\cli\main.py", line 1078, in up
  File "compose\cli\main.py", line 1074, in up
  File "compose\project.py", line 548, in up
  File "compose\service.py", line 367, in ensure_image_exists
  File "compose\service.py", line 1106, in build
  File "site-packages\docker\api\build.py", line 261, in build
  File "site-packages\docker\api\build.py", line 308, in _set_auth_headers
  File "site-packages\docker\auth.py", line 302, in get_all_credentials
  File "site-packages\docker\credentials\store.py", line 71, in list
  File "site-packages\docker\credentials\store.py", line 93, in _execute
docker.credentials.errors.StoreError: Credentials store docker-credential-desktop exited with "error listing credentials - err: exit status 1, out: `Impossibile trovare elemento.`".
[13284] Failed to execute script docker-compose

编辑:docker-compose unable to start 中接受的解决方案,不幸的是,没有工作。

出了什么问题?

最佳答案

我也有同样的问题...

尝试: $nano ~/.docker/config.json 在此文件中将 credsStore 更改为 credStore

现在运行你的 docker-compose。如果它不起作用,请尝试 sudo

关于Docker: error using docker-compose up on the official getting started tutorial,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63579685/

相关文章:

java - Docker 使用 Spring 和 mysql 镜像将推送推送到注册表

mysql - 如何在 docker-compose 文件中为具有不同 mysqld 版本的不同项目组织 mysql 卷?

node.js - 如何使用 nginx docker 容器访问 localhost 上的服务器?

ruby-on-rails - 在Docker上对ruby进行 bundle 优化

docker - Docker容器链接不在env或/etc/hosts中

linux - Docker 不下载推荐的包

docker - Dockerfile 中的多 RUN 与单链 RUN,哪个更好?

docker - 在docker中,如何关闭dockerfile暴露的端口?

azure - 运行多容器应用程序时,适用于容器的 Azure Web App 是否支持 ssh 访问?

node.js - Docker-compose up 以代码 1 退出,但 docker-compose build 成功