@@ -142,6 +142,22 @@ For information about enabling IPVS mode with kubeadm see:
142
142
For information about passing flags to control plane components see:
143
143
- [ control-plane-flags] ( /docs/setup/production-environment/tools/kubeadm/control-plane-flags/ )
144
144
145
+ ### Running kubeadm without an Internet connection {#without-internet-connection}
146
+
147
+ For running kubeadm without an Internet connection you have to pre-pull the required control-plane images.
148
+
149
+ You can list and pull the images using the ` kubeadm config images ` sub-command:
150
+
151
+ ``` shell
152
+ kubeadm config images list
153
+ kubeadm config images pull
154
+ ```
155
+
156
+ You can pass ` --config ` to the above commands with a [ kubeadm configuration file] ( #config-file )
157
+ to control the ` kubernetesVersion ` and ` imageRepository ` fields.
158
+
159
+ All default ` k8s.gcr.io ` images that kubeadm requires support multiple architectures.
160
+
145
161
### Using custom images {#custom-images}
146
162
147
163
By default, kubeadm pulls images from ` k8s.gcr.io ` . If the
@@ -151,13 +167,24 @@ requested Kubernetes version is a CI label (such as `ci/latest`)
151
167
You can override this behavior by using [ kubeadm with a configuration file] ( #config-file ) .
152
168
Allowed customization are:
153
169
170
+ * To provide ` kubernetesVersion ` which affects the version of the images.
154
171
* To provide an alternative ` imageRepository ` to be used instead of
155
172
` k8s.gcr.io ` .
156
- * To set ` useHyperKubeImage ` to ` true ` to use the HyperKube image.
157
- * To provide a specific ` imageRepository ` and ` imageTag ` for etcd or DNS add-on.
173
+ * To provide a specific ` imageRepository ` and ` imageTag ` for etcd or CoreDNS.
174
+
175
+ Image paths between the default ` k8s.gcr.io ` and a custom repository specified using
176
+ ` imageRepository ` may differ for backwards compatibility reasons. For example,
177
+ one image might have a subpath at ` k8s.gcr.io/subpath/image ` , but be defaulted
178
+ to ` my.customrepository.io/image ` when using a custom repository.
158
179
159
- Please note that the configuration field ` kubernetesVersion ` or the command line flag
160
- ` --kubernetes-version ` affect the version of the images.
180
+ To ensure you push the images to your custom repository in paths that kubeadm
181
+ can consume, you must:
182
+
183
+ * Pull images from the defaults paths at ` k8s.gcr.io ` using ` kubeadm config images {list|pull} ` .
184
+ * Push images to the paths from ` kubeadm config images list --config=config.yaml ` ,
185
+ where ` config.yaml ` contains the custom ` imageRepository ` , and/or ` imageTag `
186
+ for etcd and CoreDNS.
187
+ * Pass the same ` config.yaml ` to ` kubeadm init ` .
161
188
162
189
### Uploading control-plane certificates to the cluster
163
190
@@ -209,19 +236,6 @@ value to the kubelet.
209
236
210
237
Be aware that overriding the hostname can [ interfere with cloud providers] ( https://github.com/kubernetes/website/pull/8873 ) .
211
238
212
- ### Running kubeadm without an internet connection
213
-
214
- For running kubeadm without an internet connection you have to pre-pull the required control-plane images.
215
-
216
- You can list and pull the images using the ` kubeadm config images ` sub-command:
217
-
218
- ``` shell
219
- kubeadm config images list
220
- kubeadm config images pull
221
- ```
222
-
223
- All images that kubeadm requires such as ` k8s.gcr.io/kube-* ` , ` k8s.gcr.io/etcd ` and ` k8s.gcr.io/pause ` support multiple architectures.
224
-
225
239
### Automating kubeadm
226
240
227
241
Rather than copying the token you obtained from ` kubeadm init ` to each node, as
0 commit comments