Test and development of the system-Docker container installation

陈琦
中文

As we mentioned in the previous article, a container is a process running on a host, and multiple containers use the operating system kernel on the same host. Here takes the Ubuntu20.04 system as an example to introduce the installation process of the Docker container engine.

Install

  1. Installation dependencies.
sudo apt update
sudo apt install apt-transport-https ca-certificates curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
  1. Add software sources.
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
  1. Install the latest version of Docker.
sudo apt update
sudo apt install docker-ce docker-ce-cli containerd.io
  1. Check service status
sudo systemctl status docker

Test Docker service

  1. Execute the following command to add the current user to the docker user group.
sudo usermod -aG docker $USER
  1. Log out and log in again.
  2. Execute the following command to run the sample container.
docker run hello-world

If the message Hello from Docker can be output, the installation is successful.

thematic catalog

阅读 1.1k

资深敏捷测试顾问,开源软件作者。国内知名项目管理软件—禅道团队成员。

147 声望
3.3k 粉丝
0 条评论

资深敏捷测试顾问,开源软件作者。国内知名项目管理软件—禅道团队成员。

147 声望
3.3k 粉丝
文章目录
宣传栏