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
Revert "only pull images that can't build" #7039
Conversation
This reverts commit c6dd7da. Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Correct, in my case I'm using Though...
I would be much more in favor of not just adding documentation but actually fixing the issue (the right way). |
So I don't understand this reversion, it looks like the bug was fixed and now you've just broken it again? You said:
But this change that was just reverted did cover that case, no? For those two bugs listed here it appears that they are "by design" and were previously explained by the documentation. They should then simply call "docker-compose build" and their problems are solved. I guess I would not have recommended reversion as the fix here, perhaps I could see adding an automatic build step for images that aren't already built but I think this reversion was probably a mistake. |
I think I understand... the folks with the issue are using the same file to pull from prod for local work instead of building but they can build it locally if they wanted to by explicitly using the build command. One question about that, if you But if that's the case I would propose this, which I think would still work for these users but would also work for my use case:
I noticed one of the users had an image such as For bonus points a |
Some people indeed use image as a "build cache" so that Others do use image as tag for the image being built and pushed to a registry, assuming the same compose file can later be used to pull back on production servers, fully ignoring the build section. Once we get 1.25.1 released I'll discuss with maintainers so we create better documentation on this topic and/or introduce explicit flags so one get full control on whats happening. |
Sounds good thanks. |
See #7052 as my proposed "better" (?) fix for this issue |
Yes, this is very important for our use case. We build images in CI so that a new user can pull them (to provide the best OOTB experience), while the user should also be able to build the images locally. Thanks for reverting. |
#6494 fix is incorect
a service can define both
image
andbuild
, and documentation gives some indications on how those are handled:unfortunately those indication are not command-specific and the
pull
command documentation doesn't cover this specific case.Some use
image
to tag built services and later push images, which will be pulled by others. Some useimage
only as a "build cache" and then don't expect compose to pull those from registry. AFAICT this is the case for #6464 - can you please confirm @justinmchase ?I also can see lack of clarification on the expectation when both
build
andimage
are set brings many ambiguities, see #3853I propose we first revert change, so 1.25 will behave like 1.24 did, then work on better documentation on
docker-compose pull
and impacts ofbuild
andimage
combination for a service.About #6464,
--ignore-pull-failures
should be enough to offer a reasonable workaround.This PR reverts commit c6dd7da.
Resolves #7038
Resolves #6934