-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docker compose pull fails with non zero if it contains image that needs to be built #8805
Comments
I can confirm this, both for 2.0.0 and 2.0.1. If I have any image which should be build locally and does not exist on Docker Hub, fails with Workaround is indeed to run with |
You can use |
Ok, but why is the behavior changed. Shouldn't the two versions be functionally equal? |
sure, I just suggested this as a temporary workaround. |
Ran into this issue today on v2.2.3 while spinning up a dev/test environment for a project I'm working on. Here's my version: '3'
services:
db:
image: 'mcr.microsoft.com/mssql/server:2019-CU10-ubuntu-20.04'
environment:
ACCEPT_EULA: Y
SA_PASSWORD: ${DB_PWD}
TZ: America/Chicago
ports:
- '127.0.0.1:1433:1433'
volumes:
- './db/data:/var/opt/mssql/data:rw'
- './db/log:/var/opt/mssql/log:rw'
- './db/secrets:/var/opt/mssql/secrets:rw'
mq:
image: rabbitmq:3.8-management-alpine
environment:
TZ: America/Chicago
ports:
- '127.0.0.1:5672:5672'
- '127.0.0.1:15672:15672'
volumes:
- './mq:/var/lib/rabbitmq:rw'
ctl:
build: ./build
image: app
depends_on: [db, mq]
environment: &env
TZ: America/Chicago
DB_PWD: ${DB_PWD}
DB_HOST: db
RABBIT_MQ_HOST: mq
SERVER_MODE: CONTROLLER
ports:
- '127.0.0.1:8080:8080'
wk1: &worker
image: app
depends_on: [ctl, db, mq]
environment:
<<: *env
SERVER_MODE: WORKER
wk2: *worker
wk3: *worker
wk4: *worker Starting from a fresh state,
Summary:
Thanks for everything you've already done: docker and compose have greatly simplified my workflow. Keep up the great work! |
I can easily confirm this issue: docker-compose.ymlversion: '3'
services:
original:
image: hello-world
local:
build: .
image: foo/bar:v1 DockerfileFROM hello-world Running
When adding
(This fortunately only affects For comparison running
|
I have this issue too. I'm using AWS Elastic Beanstalk and it forces to use "docker compose pull" command. I can not edit or manipulate this step, and therefore my build breaks every time. Because of this I have downgrade my platform version which using 1.29.2 version for Docker Compose. If someone has this error in AWS Elastic Beanstalk like me, use "Docker running on 64bit Amazon Linux 2/3.5.9" platform version. Is there any progress for this? |
@kalaomer why not use |
I can not use it, it is handled by elastic beanstalk's deployment operation. I can not manipulate this command. |
This requires the following changes: * In v2, one invokes it as `docker compose` rather than `docker-compose`. * For whatever reason, `docker compose pull` will produce the following error on `s2nTests/docker-compose.yml`: ``` 3 errors occurred: * Error response from daemon: pull access denied for awslc, repository does not exist or may require 'docker login': denied: requested access to the resource is denied * Error response from daemon: pull access denied for blst, repository does not exist or may require 'docker login': denied: requested access to the resource is denied * Error response from daemon: pull access denied for s2n, repository does not exist or may require 'docker login': denied: requested access to the resource is denied ``` This is because the images are locally buildable. Some searching uncovered docker/compose#8805, which reveals that a workaround is to use `docker compose pull --ignore-buildable`. I have no idea why the behavior changed in this way from v1 to v2, but oh well. I've applied the workaround here. * The `version` property in `docker-compose.yml` is now deprecated (see the documentation here: https://docs.docker.com/compose/compose-file/04-version-and-name/) and will emit a warning if you attempt to use it. The fix is to delete the `version` property entirely. Fixes #2086.
This requires the following changes: * In v2, one invokes it as `docker compose` rather than `docker-compose`. * For whatever reason, `docker compose pull` will produce the following error on `s2nTests/docker-compose.yml`: ``` 3 errors occurred: * Error response from daemon: pull access denied for awslc, repository does not exist or may require 'docker login': denied: requested access to the resource is denied * Error response from daemon: pull access denied for blst, repository does not exist or may require 'docker login': denied: requested access to the resource is denied * Error response from daemon: pull access denied for s2n, repository does not exist or may require 'docker login': denied: requested access to the resource is denied ``` This is because the images are locally buildable. Some searching uncovered docker/compose#8805, which reveals that a workaround is to use `docker compose pull --ignore-buildable`. I have no idea why the behavior changed in this way from v1 to v2, but oh well. I've applied the workaround here. * The `version` property in `docker-compose.yml` is now deprecated (see the documentation here: https://docs.docker.com/compose/compose-file/04-version-and-name/) and will emit a warning if you attempt to use it. The fix is to delete the `version` property entirely. Fixes #2086.
docker compose pull fails with non zero if it contains image that needs to be built
that leads to a problem with my update chain:
docker-compose pull && docker-compose build && docker-compose up -d
Steps to reproduce the issue:
Dockerfile:
Describe the results you received:
docker-compose pull fails with RC=18 and && commands are not run
Describe the results you expected:
docker-compose pull skips build image, returns true and && commands are run
Output of
docker compose version
:Output of
docker info
:Additional environment details:
The text was updated successfully, but these errors were encountered: