Skip to content

Commit

Permalink
Add example for dummy route in airgap (#138)
Browse files Browse the repository at this point in the history
* Add example for dummy route in airgap

Signed-off-by: Derek Nola <derek.nola@suse.com>

* Update docs/installation/airgap.md

Co-authored-by: Brad Davidson <brad@oatmail.org>
Signed-off-by: Derek Nola <derek.nola@suse.com>

---------

Signed-off-by: Derek Nola <derek.nola@suse.com>
Co-authored-by: Brad Davidson <brad@oatmail.org>
  • Loading branch information
dereknola and brandond committed Jun 6, 2023
1 parent 7a86ad7 commit 2afd3dc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion docs/installation/airgap.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,13 @@ Once you have completed this, you may now go to the [Install K3s](#install-k3s)
- Before installing K3s, complete the [Private Registry Method](#private-registry-method) or the [Manually Deploy Images Method](#manually-deploy-images-method) above to prepopulate the images that K3s needs to install.
- Download the K3s binary from the [releases](https://github.com/k3s-io/k3s/releases) page, matching the same version used to get the airgap images. Place the binary in `/usr/local/bin` on each air-gapped node and ensure it is executable.
- Download the K3s install script at [get.k3s.io](https://get.k3s.io). Place the install script anywhere on each air-gapped node, and name it `install.sh`.
- K3s requires a default route in order to auto-detect the node's primary IP, and for kube-proxy ClusterIP routing to function properly. Therefore, a default route must be configured on each node, even if that route is a dummy route or a black hole.
- If your nodes do not have an interface with a default route, a default route must be configured; even a black-hole route via a dummy interface will suffice. K3s requires a default route in order to auto-detect the node's primary IP, and for kube-proxy ClusterIP routing to function properly. To add a dummy route, do the following:
```
ip link add dummy0 type dummy
ip link set dummy0 up
ip addr add 169.254.255.254/31 dev dummy0
ip route add default via 169.254.255.255 dev dummy0 metric 1000
```

When running the K3s script with the `INSTALL_K3S_SKIP_DOWNLOAD` environment variable, K3s will use the local version of the script and binary.

Expand Down

0 comments on commit 2afd3dc

Please sign in to comment.