github.com/cilium/cilium@v1.16.2/Documentation/installation/k0s.rst (about) 1 .. only:: not (epub or latex or html) 2 3 WARNING: You are looking at unreleased Cilium documentation. 4 Please use the official rendered version released here: 5 https://docs.cilium.io 6 7 .. _k0s_install: 8 9 ***************************** 10 Installation k0s Using k0sctl 11 ***************************** 12 13 This guide walks you through installation of Cilium on `k0s <https://k0sproject.io/>`_, 14 an open source, all-inclusive Kubernetes distribution, 15 which is configured with all of the features needed to build a Kubernetes cluster. 16 17 Cilium is presently supported on amd64 and arm64 architectures. 18 19 Install a Master Node 20 ===================== 21 22 Ensure you have the k0sctl binary installed locally. 23 24 Setup your VMs: 25 26 How to do this is out of the scope of this guide, please refer to your favorite virtualization tool. 27 After deploying the VMs, export their IP addresses to environment variables (see example below). These will be used in a later step. 28 29 .. code-block:: shell-session 30 31 export node1-IP=192.168.2.1 node2-IP=192.168.2.2 node3-IP=192.168.2.3 32 33 34 Prepare the yaml configuration file k0sctl will use: 35 36 .. code-block:: shell-session 37 38 # The following command assumes the user has deployed 3 VMs 39 # with the default user "k0s" using the default ssh-key (without passphrase) 40 k0sctl init --k0s -n "myk0scluster" -u "k0s" -i "~/.ssh/id_rsa" -C "1" "${node1-IP}" "${node2-IP}" "${node3-IP}" > k0s-myk0scluster-config.yaml 41 42 43 Next step is editing ``k0s-myk0scluster-config.yaml``:: 44 45 # replace 46 ... 47 provider: kube-router 48 ... 49 # with 50 ... 51 provider: custom 52 ... 53 54 Finally apply the config file: 55 56 .. code-block:: shell-session 57 58 k0sctl apply --config k0s-myk0scluster-config.yaml --no-wait 59 60 61 .. note:: 62 63 If running Cilium in :ref:`kubeproxy-free` mode disable kube-proxy in the k0s config file 64 65 66 .. code-block:: shell-session 67 68 # edit k0s-myk0scluster-config.yaml 69 70 # replace 71 ... 72 network: 73 kubeProxy: 74 disabled: false 75 ... 76 # with 77 ... 78 network: 79 kubeProxy: 80 disabled: true 81 ... 82 83 Configure Cluster Access 84 ======================== 85 86 For the Cilium CLI to access the cluster in successive steps you will need to 87 generate the ``kubeconfig`` file, store it in ``~/.kube/k0s-mycluster.config`` and setting 88 the ``KUBECONFIG`` environment variable: 89 90 .. code-block:: shell-session 91 92 k0sctl kubeconfig --config k0s-myk0scluster-config.yaml > ~/.kube/k0s-mycluster.config 93 export KUBECONFIG=~/.kube/k0s-mycluster.config 94 95 Install Cilium 96 ============== 97 98 .. include:: cli-download.rst 99 100 Install Cilium by running: 101 102 .. parsed-literal:: 103 104 cilium install |CHART_VERSION| 105 106 Validate the Installation 107 ========================= 108 109 .. include:: cli-status.rst 110 .. include:: cli-connectivity-test.rst 111 112 .. include:: next-steps.rst