How to install Docker on Linux Mint 18

This entry is part 2 of 4 in the series Instructions for installing and using the Docker

SystemMen - This article will guide you to install Docker on Linux Mint.

Docker is mainly used on Linux computers, including servers and personal computers. Developers can install Docker on their computers and create perfect dev environments.

Add Docker GPG key to Linux Mint

You can switch to user root to execute commands or use sudo.

Update the package.

$ sudo apt-get update -y

Because we need to add Docker repository to the computer and to avoid encountering errors when adding GPG key, we will install packages according to the following command.

$ sudo apt-get install apt-transport-https ca-certificates curl software-properties-common -y

Next, we add Docker’s official GPG key.

$ curl -fsSL | sudo apt-key add -

Now we will check if the added key matches the following text range.

9DC8 5822 9FC7 DD38 854A E2D8 8D81 803C 0EBF CD88

The command to check.

$ sudo apt-key fingerprint 0EBFCD88

Check your distribution name

You know, the Linux Mint or Ubuntu versions have their names, in order to be able to add the exact repository for your OS version, you need to specify the name first.

how-to-install-docker-on-linux-mint-18 How to install Docker on Linux Mint 18
How to install Docker on Linux Mint 18.

You type the command below.

danie@linuxmint ~ $ lsb_release -cs

For example, my computer is using the sylvia version, your computer may be a xenial example.

Add repository and install Docker in Linux Mint

Now, type the following command to add a repository to your computer. Replace the word sylvia with your operating system name.

$ sudo add-apt-repository "deb [arch=amd64] sylvia stable"

Then, we update the software packages in the computer.

$ sudo apt-get update -y

Finally, run the following command to install Docker.

$ sudo apt-get install docker-ce -y

You can verify whether Docker CE is installed correctly by creating a container with the hello-world image.

$ sudo docker run hello-world


So you have successfully installed Docker CE on your computer, you can try to create some simple containers to experience Docker.

In the next article, we will learn how to work with Docker.

Continue reading the series«« Previous part: Introduction to Docker technologyNext part: How to search for a container image »»

«« »»