-
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
Offline docs do not work for the Docker driver #10149
Comments
@ricosega Thank you for opening this. Following for updates. |
Hey @ricosega thanks for opening this issue. A few questions:
Running Could you provide the following output when run offline?
|
Hi @priyawadhwa , Ubuntu 18.04 and 20.04. All this versions have the same behavior.
The problem is not when you're online, the command |
Hi @ricosega sorry, I meant to say this: Running minikube start --download-only with a network connection should (in theory) be enough to run minikube start successfully offline. When you run Could you try:
and let me know if that works? Thanks. |
I agreed that offline usage should in fact work -- we even have an integration test for it. Offline support was introduced before the Docker driver was implemented, and we haven't yet updated the documentation to reflect one major quirk about the Docker driver: it does not pull the image from the local filesystem, but instead pulls it from the local Docker daemon. |
There was a bit of a twist in this story, it was not only "offline" (on the same host) but also on a different host... But it is mentioned in the documentation:
Which sortof implies that everything is cached there. |
In the suggested PR #10918, the image is stored in ~/.minikube/cache/kic folder:
This means that it will be copied to the other machine, and available offline as well. When the first node is started, it will get loaded into Docker daemon (or Podman) |
Will be in 1.20 |
Hi there,
Needed to set up minikube in an "air gapped/offline" environment and we were not able to to do it following the instructions. We tried using many flags at start point like,
--cache-images=true
, or--download-only
, and many combinations, but when we moved the .minikube folder to the offline computers, it wasn't able to start.We also tried using
minikube cache load $image
with all of the needed images and same result. Finally I tried downloading thegcr.io/k8s-minikube/kicbase
, moving it to the offline and starting it withminikube --base-image="privateregistry/minikubeimage
and it worked.Moreover, when you are in an offline environment most probably you will use a private registry so passing the flag
--registry-mirror="https://privateregistry
is not enough to make it work, because when you apply any definition yaml it doesn't works because of the error: "x509: certificate signed by unknown authority" which you have documented here, and wanted to confirm that there is no need to create the folders~/.minikube/files/etc/ssl/certs
, if you copy your certificate directly to~/.minikube/certs/
it also works.Finally, the last step won't work because minikube does not know the DNS resolution to the private registry, so you have to either, inside of the minikube docker container add your private DNS to the
/etc/resolv.conf
or directly set the private reigistry resolution at the/etc/hosts
which can be solved by for example usingdocker exec -it minikube bash -c "echo '$IP $REGISTRYNAME' >> /etc/hosts
. Is there some way to make this persistent across restarts? Would be a new feature to make the flag--dns-proxy
also compatible with docker?The text was updated successfully, but these errors were encountered: