2023-12-23 05:47:02 +00:00
|
|
|
# 05 | Join Additional Controller and Worker Nodes
|
2023-12-19 14:12:07 +00:00
|
|
|
|
2023-12-23 05:24:31 +00:00
|
|
|
At this point, other nodes can be joined to the cluster. From a control node, you can get the join command by doing the following.
|
|
|
|
|
|
|
|
```bash
|
|
|
|
sudo kubeadm token create --print-join-command
|
|
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
You can then take the command in the output and use it to join other nodes.
|
|
|
|
|
2023-12-19 14:12:07 +00:00
|
|
|
```bash
|
|
|
|
|
2023-12-23 05:24:31 +00:00
|
|
|
# Example to join a control node, add --control-plane
|
|
|
|
sudo kubeadm join 10.69.69.50:6443 --token drazx3.qa70i6wfatxujdqo --discovery-token-ca-cert-hash sha256:5dccc0b4113ffc2543e2d453c35bf4db998719c1c73b60e4467f5c20d3f7b9ad --control-plane
|
|
|
|
|
|
|
|
# Example to join a worker node
|
|
|
|
sudo kubeadm join 10.69.69.50:6443 --token drazx3.qa70i6wfatxujdqo --discovery-token-ca-cert-hash sha256:5dccc0b4113ffc2543e2d453c35bf4db998719c1c73b60e4467f5c20d3f7b9ad
|
2023-12-19 14:12:07 +00:00
|
|
|
|
2023-12-23 05:24:31 +00:00
|
|
|
```
|