Air-Gap Install
You can install K3s in an air-gapped environment using two different methods. An air-gapped environment is any environment that is not directly connected to the Internet. You can either deploy a private registry and mirror docker.io, or you can manually deploy images such as for small clusters.
Load Images
Private Registry Method
These steps assume you have already created nodes in your air-gap environment, are using the bundled containerd as the container runtime, and have a OCI-compliant private registry available in your environment.
If you have not yet set up a private Docker registry, refer to the official Registry documentation.
Create the Registry YAML and Push Images
- Obtain the images archive for your architecture from the releases page for the version of K3s you will be running.
- Use
docker image load k3s-airgap-images-amd64.tar.zst
to import images from the tar file into docker. - Use
docker tag
anddocker push
to retag and push the loaded images to your private registry. - Follow the Private Registry Configuration guide to create and configure the
registries.yaml
file. - Proceed to the Install K3s section below.
Manually Deploy Images Method
These steps assume you have already created nodes in your air-gap environment, are using the bundled containerd as the container runtime, and cannot or do not want to use a private registry.
This method requires you to manually deploy the necessary images to each node, and is appropriate for edge deployments where running a private registry is not practical.