-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Add code for downloading kicbase image to cache #10918
Conversation
Download the image to the cache, instead of to the daemon. This way it also works for Podman, and not only for Docker
/ok-to-test |
kvm2 Driver |
Note that in order to make this work for Podman, we need to fix case driver.Podman:
return fmt.Errorf("not yet implemented, see issue #8426") It would also be nice to avoid loading again, if the image is already present in the container engine... For this to happen, we need to use something other than go-containerregistry. Since it only supports Docker, as can be seen indirectly in the |
But the current daemon.Write is quite stupid, so not too hard to re-implement with podman: https://github.com/google/go-containerregistry/blob/main/pkg/v1/daemon/write.go#L57 Instead of using github.com/docker/docker/client, one could just fork a If we want to implement the lookup, we would also need something instead of daemon.Image This is the other end, so instead of // Write saves the image into the daemon as the given tag. // Tag adds a tag to an already existent image. // Image provides access to an image reference from the Docker daemon, |
kvm2 driver with docker runtime
Times for minikube ingress: 35.3s 35.8s 34.3s 36.8s 34.2s Times for minikube start: 48.5s 49.7s 51.7s 47.4s 47.9s docker driver with docker runtime
Times for minikube ingress: 28.0s 29.0s 28.5s 34.0s 29.0s Times for minikube start: 23.2s 20.6s 21.6s 21.3s 20.8s docker driver with containerd runtime |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: afbjorklund, medyagh The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Looks good to me , Thank you for this PR |
Download the image to the cache, instead of to the daemon.
This way it also works for Podman, and not only for Docker
Left to decide:
Should we store the KIC images in a separate directory
Before they were mixed with the container runtime images
Delete the old Docker-only code, only use the cache ?
This means not using the digest, always load from files
Currently the image is 354M on the disk (gz-compressed)
Closes #10912 #7766