HomeLinuxHow To Set up Docker Desktop on Ubuntu and Linux Mint

How To Set up Docker Desktop on Ubuntu and Linux Mint


Docker Desktop is an easy-to-use cross-platform GUI (Graphical Consumer Interface) software used to handle Docker photos, containers, and apps out of your native laptop. It may be utilized both independently or at the side of the command-line interface shopper.

A complete Docker growth atmosphere may be shortly put in and arrange utilizing Docker Desktop, which additionally helps quite a lot of programming languages and frameworks. It comes pre-installed with the latest model of Kubernetes, the Docker engine, the Docker CLI shopper, Docker Buildx, Docker Compose, extensions, and the Docker Content material Belief.

With native Home windows Hyper-V virtualization, it supplies fast and reliable efficiency on Home windows and allows you to swap between the Linux and Home windows Server environments with ease when growing purposes. Moreover, it might function natively on Linux on Home windows computer systems by way of the Home windows Subsystem for Linux 2 (also called WSL 2).

In addition to, Docker Desktop gives file change notifications, quantity mounting for code and information, and easy entry to lively containers on the native host community.

This information exhibits the way to set up Docker Desktop on Ubuntu and its derivatives, comparable to Linux Mint. Our check atmosphere is Ubuntu 22.04.

This information exhibits the way to set up Docker Desktop on Ubuntu 22.04 and Ubuntu-based distributions comparable to Linux Mint.

Conditions:

  • 64-bit kernel and CPU help for virtualization/KVM virtualization help.
  • QEMU have to be model 5.2 or newer (however the newest model is beneficial).
  • Systemd init system.
  • GNOME, KDE, or MATE Desktop atmosphere.
  • At the least 4 GB of RAM, and.
  • Allow configuring ID mapping in person namespaces.

1. Checking KVM Virtualization Assist in Ubuntu

As talked about below the prerequisite part above, Docker Desktop runs a digital machine that requires KVM help. If the host has virtualization help, the KVM module ought to load robotically. However, you possibly can load the module manually by operating the next command:

$ modprobe kvm

You may run the next instructions relying on the processor of the host machine to load the corresponding module:

$ modprobe kvm_intel  [For Intel]
$ modprobe kvm_amd    [For AMD]  

To verify if KVM acceleration can be utilized in your machine, problem the next command:

$ kvm-ok
Check KVM Virtualization Support in Ubuntu
Examine KVM Virtualization Assist in Ubuntu

Subsequent, additionally verify if the KVM modules are enabled, by operating the next command:

$ lsmod | grep kvm
Check KVM Modules
Examine KVM Modules

Now that the stipulations exist in your machine, proceed to put in Docker Desktop as described within the sections that comply with.

2. Set up Docker Repository in Ubuntu

Now, run the next instructions first to replace the native package deal index, then set up the required packages, create a repository to retailer the Docker APT repository key, set up the important thing, after which arrange the repository configuration file:

$ sudo apt-get replace
$ sudo apt-get set up ca-certificates curl gnupg lsb-release
$ sudo mkdir -m 0755 -p /and so forth/apt/keyrings
$ curl -fsSL https://obtain.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /and so forth/apt/keyrings/docker.gpg
$ echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://obtain.docker.com/linux/ubuntu $(lsb_release -cs) secure" | sudo tee /and so forth/apt/sources.checklist.d/docker.checklist > /dev/null

3. Set up Docker Desktop on Ubuntu

Subsequent, obtain the Docker Desktop DEB package deal file utilizing the wget command-line downloader as follows:

$ wget -c https://desktop.docker.com/linux/most important/amd64/docker-desktop-4.17.0-amd64.deb

Then, as soon as once more replace the native package deal index and set up DEB package deal utilizing the apt command as proven.

$ sudo apt replace
$ sudo apt set up ./docker-desktop-4.17.0-amd64.deb

Observe: Earlier than you begin operating the applying, do not forget that on Linux, Docker Desktop runs a Digital Machine (VM) so it creates and makes use of a customized docker context desktop-linux on startup.

Subsequently, should you had deployed any photos and containers on the Linux Docker Engine earlier than the set up, they won’t be out there in Docker Desktop for Linux.

3. Utilizing Docker Desktop on Ubuntu

As soon as the Docker Desktop software has been efficiently put in, seek for it within the Actions or Purposes menu. Then click on on it icon as proven within the following screenshot.

Subsequent, the Docker menu will show the Docker Subscription Service Settlement window, learn via it and click on Settle for to proceed as highlighted within the subsequent screenshot.

Docker Subscription Service Agreement
Docker Subscription Service Settlement

Beginning Container Utilizing Docker Desktop

It’s time to run your first container utilizing Docker Desktop by operating the next command.

$ docker run -d -p 80:80 docker/getting-started 
Running Docker Container
Working Docker Container

After operating the above command, it’s best to now see a container operating as proven within the subsequent screenshot.

Docker Container Running
Docker Container Working

Click on the increase arrow subsequent to the port mapping, below the Port(s) column to view the easy static website operating within the container, in your internet browser.

Site Running in Container
Website Working in Container

Congratulations! You might have efficiently put in Docker Desktop in your Ubuntu machine and run a pattern container. For extra info, learn via the Getting Began information offered by the static website within the pattern container or view the on-line documentation.

If You Respect What We Do Right here On TecMint, You Ought to Contemplate:

TecMint is the quickest rising and most trusted neighborhood website for any sort of Linux Articles, Guides and Books on the internet. Tens of millions of individuals go to TecMint! to go looking or browse the 1000’s of printed articles out there FREELY to all.

For those who like what you might be studying, please take into account shopping for us a espresso ( or 2 ) as a token of appreciation.

Support Us

We’re grateful in your by no means ending help.

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments