Install k3s+docker Offline
Background description
In some scenarios, the edge node cannot be connected to the public network. At this time, you can install k3s and docker offline. This section focuses on the offline installation method of k3s and docker.
Get offline installation package
- Download the offline installation package k3s-install.zip, and then copy it to the edge node.
- Decompress the k3s offline installation package, and execute the following command:
unzip k3s-install.zip
Decompress it to get the following files:
Architecture description: This installation package supports the k3s+docker installation of the amd64, arm64, and arm32 architecture, and the installation script will automatically use the matching installation package based on the architecture of the current edge node.
Offline installation of docker
- Execute the docker installation command:
./docker-install.sh
Note: Do not press
CTRL+C
to interrupt the installation process during installation.
- View the running status of k3s.
systemctl status docker
As shown in the figure below, it verifies that the docker runs normally.
- Common Commands
systemctl start docker
systemctl stop docker
Offline installation of k3s
- Execute the k3s installation command.
./k3s-install.sh
- If you use docker as the container runtime of k3s, select
no
in the interaction command as shown in the figure below.
Note: Do not press
CTRL+C
to interrupt the installation process during installation.
- View the running status of k3s.
systemctl status k3s
As shown in the figure below, it verifies that k3s runs normally.
- If you use containerd as the container runtime of k3s, select
yes
in above step 2.