-
Notifications
You must be signed in to change notification settings - Fork 362
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
Pull the image given in CACHE_FROM argument #885
Conversation
Write a function that takes in a list of docker images that are desired cache sources for the build phase. Check each image name for a provided tag, if not found then default to 'latest'. Pull each image from Docker Hub, they then will be available locally to be used as a cache during the build phase.
This looks nice! Not super sure where we could put things. Like you say it is related to If we can make them three separate functions that take their inputs as arguments and then do their thing that would be nice I think. It would also make them easier to test because you don't need to setup the whole app first. |
I'll take a look at #848, I had lost track of that PR |
Just following up on this and/or #848 :) |
I agree its not so intuitive that It is a passthrough option to the I'll go for a close on this for now to help triage PRs in this project, please don't see that as a final decision or similar! Update - Did we all misunderstand
|
Summary
Write a function that takes in a list of docker images that are
desired cache sources for the build phase. Check each image name
for a provided tag, if not found then default to 'latest'. Pull
each image from Docker Hub, they then will be available locally
to be used as a cache during the build phase.
This was the behaviour I expected to see when using the CACHE_FROM flag, but it appears that this is not the case. Issue #130
I have written a function that consumes the list of images, checks for tags and then pull them. I'm not sure where to put this within the repo2docker codebase though, so any guidance on that would be super appreciated ✨
It may also be useful to combine with the
find_image
function so we don't pull what we already have? https://github.com/jupyter/repo2docker/blob/bbc3ee02c0755b15ea456f9ae18dd76b904568e7/repo2docker/app.py#L613-L625Outstanding TODOs
push_image
https://github.com/jupyter/repo2docker/blob/bbc3ee02c0755b15ea456f9ae18dd76b904568e7/repo2docker/app.py#L458-L499