In the following, we give examples for Debian-based operating systems using the
apt
package manager. If you are using an OS with a different package manager (for example, Fedora Linux with theyum
package manager), please adapt the commands shown to your specific system.
First, please ensure that your system is up-to-date and has the latest OS kernel installed.
sudo apt-get update
sudo apt-get upgrade
Next, install the Docker
runtime, as well has the docker-compose
stack. Create a file install-docker.sh
with the following contents:
#!/bin/bash
# This file is install-docker.sh
# Set terminal output
set -xe
# Install Docker
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
# Install docker-compose 1.26.2
sudo curl \
-L "https://github.com/docker/compose/releases/download/1.26.2/docker-compose-$(uname -s)-$(uname -m)" \
-o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
Then set this file as executable and run it to add the docker
and docker-compose
commands to your system:
chmod a+x install-docker.sh
./install-docker.sh
The following commands should run successfully and print the version numbers for docker
and docker-compose
:
docker -v
docker-compose -v
Finally, install the native WireGuard® network protocol and kernel extensions for your OS:
sudo apt-get update
sudo apt-get install -y wireguard wireguard-dkms wireguard-tools
The following command should run successfully and print the version number for wireguard-tools
:
wg -v
Now it is time to reboot the host:
sudo reboot now