-
Notifications
You must be signed in to change notification settings - Fork 715
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
Check if all images already exist, before pulling the images #3145
Comments
The existing images will be skipped. You can see the detailed info by # kubeadm init phase preflight -v 1
...
[preflight] Pulling images required for setting up a Kubernetes cluster
[preflight] This might take a minute or two, depending on the speed of your internet connection
[preflight] You can also perform this action in beforehand using 'kubeadm config images pull'
I0104 02:50:25.901834 3238 checks.go:828] using image pull policy: IfNotPresent
I0104 02:50:25.934956 3238 checks.go:846] image exists: registry.k8s.io/kube-apiserver:v1.28.15
I0104 02:50:25.969421 3238 checks.go:846] image exists: registry.k8s.io/kube-controller-manager:v1.28.15
I0104 02:50:26.004269 3238 checks.go:846] image exists: registry.k8s.io/kube-scheduler:v1.28.15
I0104 02:50:26.039219 3238 checks.go:846] image exists: registry.k8s.io/kube-proxy:v1.28.15
I0104 02:50:26.098499 3238 checks.go:846] image exists: registry.k8s.io/pause:3.9
I0104 02:50:26.125516 3238 checks.go:846] image exists: registry.k8s.io/etcd:3.5.9-0
I0104 02:50:26.152237 3238 checks.go:846] image exists: registry.k8s.io/coredns/coredns:v1.10.1
... |
I know. What I wanted to be skipped is the output (not the verbose log), repeating the same instructions. Here is the script that I used (redacted):
And then you still get the output like:
So I already did the pull, and it is redundant.
Probably should stop the (unconfigured) kubelet service, while it is pulling the images? But then again the images should probably be downloaded and cached, even earlier... With k3s or with minikube they are using their own airgapped and preloaded tarballs. But we don't have that infrastructure for Kubernetes, there are no such tarballs available. |
i gave the idea how it can be better implemented here but these few kubeadm lines are linear and not too output-poluting.
combining the logs from multiple tools in the same output seems bad. there is a tracking issue to not start the kubelet with a crashloop until kubeadm prepares the config, but it also requires deb/rpm package updates, and maybe a KEP to polish all corner cases: |
Is this a BUG REPORT or FEATURE REQUEST?
Choose one: FEATURE REQUEST
Versions
kubeadm version (use
kubeadm version
):v1.32.0
Environment:
kubectl version
): stableuname -a
): 6.8What happened?
When running the images preflight, the message is always printed:
What you expected to happen?
If you have already pulled all the images, a more friendly message:
How to reproduce it (as minimally and precisely as possible)?
kubeadm init phase preflight
Anything else we need to know?
The text was updated successfully, but these errors were encountered: