Skip to content

Latest commit

 

History

History
55 lines (35 loc) · 1.97 KB

Install Calico.md

File metadata and controls

55 lines (35 loc) · 1.97 KB
  1. Install the Calico operator and cudtom resource definitions
kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/v3.26.1/manifests/tigera-operator.yaml

Due to the large size of the CRD bundle, kubectl apply might exceed request limits. Instead, use kubectl create or kubectl replace.

  1. Install Calico by creating the necessary custom resource. For more information on configuration options available in this manifest, see the installation reference.
kubectl create -f https://raw.githubusercontent.com/projectcalico/calico/v3.26.1/manifests/custom-resources.yaml

Before creating this manifest, read its contents and make sure its settings are correct for your environment. For example, you may need to change the default IP pool CIDR to match your pod network CIDR.

  1. Confirm that all of the pods are running with the following command.
watch kubectl get pods -n calico-system

Wait until each pod has the STATUS of Running.

The Tigera operator installs resources in the calico-system namespace. Other install methods may use the kube-system namespace instead.

  1. Remove the taints on the control plane so that you can schedule pods on it.
kubectl taint nodes --all node-role.kubernetes.io/control-plane-
kubectl taint nodes --all node-role.kubernetes.io/master-

It should return the following.

node/<your-hostname> untainted

Confirm that you now have a node in your cluster with the following command.

kubectl get nodes -o wide

It should return something like the following.

NAME              STATUS   ROLES    AGE   VERSION   INTERNAL-IP   EXTERNAL-IP   OS-IMAGE             KERNEL-VERSION    CONTAINER-RUNTIME
<your-hostname>   Ready    master   52m   v1.12.2   10.128.0.28   <none>        Ubuntu 18.04.1 LTS   4.15.0-1023-gcp   docker://18.6.1

You now have a single-host Kubernetes cluster with Calico!