Install Kubernetes (kubectl, kubeadm, kubelet) on debian stretch

9/27/2018

I would like to install Kubernetes on my debian machine:

Distributor ID: Debian
Description:    Debian GNU/Linux 9.5 (stretch)
Release:        9.5
Codename:       stretch

Looking into google deb package archive I only find the package for "kubectl", nothing else:

https://packages.cloud.google.com/apt/dists/kubernetes-stretch/main/binary-amd64/Packages

Comparing to ubuntu xenial many packages are missing. Could someone be so kind and give me more information how to deal with this ? Is it possible to install kubeadm and kubelet on debian stretch too ?

https://kubernetes.io/docs/setup/independent/install-kubeadm/#installing-kubeadm-kubelet-and-kubectl

Thank you very much in advance !

-- Maciej A. Bednarz
debian-stretch
kubernetes

1 Answer

9/27/2018

Is it possible to install kubeadm and kubelet on debian stretch too ?

Yes it is! Please refer to the helpful guide that you linked at the end of your question: https://kubernetes.io/docs/setup/independent/install-kubeadm/#installing-kubeadm-kubelet-and-kubectl

Here is the relevant part:

apt-get update && apt-get install -y apt-transport-https curl
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF >/etc/apt/sources.list.d/kubernetes.list
deb http://apt.kubernetes.io/ kubernetes-xenial main
EOF
apt-get update
apt-get install -y kubelet kubeadm kubectl
apt-mark hold kubelet kubeadm kubectl

Note, that you are using kubernetes-xenial above, not kubernetes-stretch.

Do not forget to install docker first, for how, see the same linked page above.

-- Andrew Savinykh
Source: StackOverflow