How to Install Docker on Linux Mint
Docker allows you to package and run a software application in a container (Docker container). A Docker container comprises all the essentialities for software, such as; source code, tools, libraries, or any settings. Moreover, Docker provides the continuous integration of the software modules at the development time.
This descriptive post demonstrates several methods to install Docker on Linux Mint.
How to Install Docker on Linux Mint
Docker can be installed from the official repository of Linux Mint using the Docker snap and the .deb package of Docker. To better understand, we have divided this installation guide into various sub-sections to demonstrate each method separately.
How to Install Docker on Linux Mint Using the Official Repository of Linux Mint
You need to follow various steps to get Docker from Linux Mint’s official repository:
Step 1: Firstly, update the system packages of Linux Mint by issuing the following command:
Step 2: After updating the core libraries of Linux Mint, you can install the latest Docker from the Linux Mint repository via the following command:
The command will install Docker and its dependencies, as seen in the output.
Verify the installed version of the Docker as follows:
How to Install Docker on Linux Mint Using the Debian Package
Linux Mint is the derivative of the Debian-based distributions of Linux. The Debian package of Docker can also be used to install Docker on Linux Mint.
Step 1: Download the Debian package of Docker-ce-cli.deb, containered.io.deb, and docker-ce.deb with the help of the following commands:
– For containerd.io :
– For docker-ce-cli:
– For docker-ce:
Step 2: The files can be traced inside the current directory. Now, you can install all three “.deb” files present in the Downloads directory via the following command:
You can verify the installation by issuing the below-mentioned command:
Step 3: If you want to execute the docker commands with the non-root user, you must add the user to the docker group by issuing the below-mentioned command:
After adding the current user to the docker group, you can use the docker commands without root privileges (for only currently logged-in user):
How to Install Docker on Linux Mint Using the Snap
The snap support is available on several Linux distributions to install packages using the terminal and the graphical user interface. The following steps are recommended to follow to install Docker on Linux Mint using the snap:
Step 0 (Optional): You need to enable the snap packages installation. Firstly, move/remove the “/etc/apt/preferences.d/nosnap.pref” file to allow installing snaps installation on your system. It is recommended to move the directory to some other location on the device as we did:
Now, install snapd by using the below-mentioned command:
Note: Step 0 is optional and can be skipped if you have already enabled the snapd service.
Step 1: Once the initial step is performed, then Docker can be installed using the following snap command:
The installation can be verified by issuing the below-mentioned command:
How to Remove Docker From Linux Mint
If the Docker is installed from the official repository, then you can use the following command to remove Docker and all its dependencies from Linux Mint:
However, if you have installed Docker from the snap store, then it can be removed via the below-mentioned command:
After doing so, Docker will be removed from the Linux Mint.
Docker is an open-source and cross-platform utility for software developers. Docker container integrates source code of applications with the libraries/dependencies of the Operating System. This article demonstrates the installation of Docker on Linux Mint using three different methods. You have learned to install Docker on Linux Mint: from the official repository of Linux Mint, using the Docker snap and the Debian package of Docker. We have also illustrated various ways to remove Docker from Linux Mint.