Table of contents
Docker is a platform for developing, shipping, and running applications in containers.
Containers are lightweight, portable, and self-sufficient units that can package an application and its dependencies, including libraries and configuration files, into a single, consistent environment.
This allows developers to create, deploy, and manage applications more efficiently, regardless of the underlying infrastructure.
Let's get down to business
Check your OS (optional)
This step is just to make sure you have Deepin Linux installed.
lsb_release -a hostnamectl cat /etc/os-release uname -a
Update packages info
sudo apt-get update
sudo apt-get update is an important step before installing or upgrading packages on your system because it ensures that you have the most up-to-date information about available packages.
Without updating the package index, you might not see the latest versions of software or be able to install new packages that have been added to the repositories since the last update.
sudo apt install apt-transport-https ca-certificates gnupg2 curl software-properties-common -y
Download Docker GPG (GNU Privacy Guard) key
sudo curl -fsSL https://download.docker.com/linux/debian/gpg | sudo apt-key add -
Curl is a command-line tool for transferring data with URLs. In this context, it is used to fetch data from the specified URL.
Check Docker GPG key
sudo apt-key fingerprint 0EBFCD88
0EBFCD88 is the key ID or key fingerprint of the GPG key for which you want to retrieve information. In this case,
0EBFCD88 is typically the GPG key associated with the Docker repository.
sudo apt-key fingerprint command is used to display the fingerprint of a GPG key that has been added to the APT (Advanced Package Tool) keyring on a Debian-based Linux system. The fingerprint is a unique identifier for a GPG key, and it's used to verify the authenticity of the key.
Add a new entry to the repository
printf 'deb [arch=amd64] https://download.docker.com/linux/debian buster stable\n'| sudo tee /etc/apt/sources.list.d/docker-ce.list
Update package info
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io
docker-ce is the package name for Docker CE (Community Edition), which is the version of Docker designed for community use and development environments.
Docker CE Command Line Interface (CLI) is available through the package
docker-ce-cli. It provides the command-line tools for working with Docker containers and images.
containerd.io is the package name for
containerd, which is an essential component of the Docker runtime that manages containers and provides a basic infrastructure for container execution.
docker --version which docker docker --help
sudo systemctl status docker
The command used to manage and control system services on Linux systems that use
systemdas their init system is
systemdis a system and service manager commonly used in modern Linux distributions.
Configure Docker hello-world
sudo docker pull hello-world
Run Docker hello-world
sudo docker run hello-world
Let's become friends
Thank you for reading this article.
If you have any questions, thoughts, suggestions, or corrections, please share them with us.
We appreciate your feedback and look forward to hearing from you.
Feel free to suggest topics for future blog articles. Until next time!