How to execute "kubeadm init" v1.6.4 behind firewall

6/8/2017

Is it possible to run "kubeadm init" without Internet access?

When executing kubeadm init on isolated networks where the host is not allowed to make external connections, it fails on download of a stable version check of some sort, as it tries to retrieve https://storage.googleapis.com/kubernetes-release/release/stable-1.6.txt .

# kubeadm init
[kubeadm] WARNING: kubeadm is in beta, please do not use it for production clusters.
unable to get URL "https://storage.googleapis.com/kubernetesrelease/release/stable-1.6.txt": Get https://storage.googleapis.com/kubernetes-release/release/stable-1.6.txt: dial tcp 216.58.204.80:443: i/o timeout

Why is this check needed? The contents of that URL seems to today be "v1.6.4", which is the version that is installed:

# kubeadm version
kubeadm version: version.Info{Major:"1", Minor:"6", GitVersion:"v1.6.4", GitCommit:"d6f433224538d4f9ca2f7ae19b252e6fcb66a3ae", GitTreeState:"clean", BuildDate:"2017-05-19T18:33:17Z", GoVersion:"go1.7.5", Compiler:"gc", Platform:"linux/amd64"}

This seems to be a behavior introduced after 1.6.0. I have looked at documentation, flags, configuration options but have not found a way to execute kubeadm init without this (not even with --skip-preflight-checks).

-- Rickard S
kubeadm
kubernetes

1 Answer

6/12/2017

Resolved by using the following command:

kubeadm init --kubernetes-version=v1.6.4

(Note the "v" in the version number.)

-- Rickard S
Source: StackOverflow