From 429d01e95b45e67aba70bf8bee0dd88ee27e5f0f Mon Sep 17 00:00:00 2001 From: Chuck Ha Date: Tue, 3 Jul 2018 10:37:21 -0400 Subject: [PATCH] Updates HA etcd with kubeadm (#9227) Adds a missing instruction on how to configure the kubelet. Reported in slack in the #kubeadm channel. Fixes #9222 Signed-off-by: Chuck Ha --- .../setup-ha-etcd-with-kubeadm.md | 34 ++++++++++++++++--- 1 file changed, 29 insertions(+), 5 deletions(-) diff --git a/content/en/docs/tasks/administer-cluster/setup-ha-etcd-with-kubeadm.md b/content/en/docs/tasks/administer-cluster/setup-ha-etcd-with-kubeadm.md index 2648dab3a9..2183108df5 100644 --- a/content/en/docs/tasks/administer-cluster/setup-ha-etcd-with-kubeadm.md +++ b/content/en/docs/tasks/administer-cluster/setup-ha-etcd-with-kubeadm.md @@ -22,9 +22,10 @@ when using kubeadm to set up a kubernetes cluster. document assumes these default ports. However, they are configurable through the kubeadm config file. * Each host must [have docker, kubelet, and kubeadm installed][toolbox]. -* Some infrastructure to copy files between hosts (e.g., ssh). +* Some infrastructure to copy files between hosts. For example `ssh` and `scp` + can satisfy this requirement. -[toolbox]: /docs/setup/independent/install-kubeadm/ +[toolbox]: /docs/tasks/tools/install-kubeadm/ {{% /capture %}} @@ -33,9 +34,32 @@ when using kubeadm to set up a kubernetes cluster. ## Setting up the cluster The general approach is to generate all certs on one node and only distribute -the *necessary* files to the other nodes. Note that kubeadm contains all the -necessary crytographic machinery to generate the certificates described below; -no other cryptographic tooling is required for this example. +the *necessary* files to the other nodes. + +{{< note >}} +**Note:** kubeadm contains all the necessary crytographic machinery to generate +the certificates described below; no other cryptographic tooling is required for +this example. +{{< /note >}} + + +1. Configure the kubelet to be a service manager for etcd. + + Running etcd is simpler than running kubernetes so you must override the + kubeadm-provided kubelet unit file by creating a new one with a higher + precedence. + + ```sh + cat << EOF > /etc/systemd/system/kubelet.service.d/20-etcd-service-manager.conf + [Service] + ExecStart= + ExecStart=/usr/bin/kubelet --pod-manifest-path=/etc/kubernetes/manifests --allow-privileged=true + Restart=always + EOF + + systemctl daemon-reload + systemctl restart kubelet + ``` 1. Create configuration files for kubeadm.