FROM ubuntu:20.04
WORKDIR /home/
COPY . .
RUN bash ./

Add Registry Mirrors For Ubuntu

Docker > 1.10.0

sudo mkdir -p /etc/docker
sudo tee /etc/docker/daemon.json <<-'EOF'

   "registry-mirrors": ["url"]

sudo systemctl daemon-reload
sudo systemctl restart docker

source: from Aliyun

Add Registry Mirrors For Win10

1. Install Docker for Windows

from, installation manuals

2. Add Aliyun Mirror Accelerator

  1. Open Docker Desktop

  2. Click Settings

  3. Click Docker Engine

  4. Add url to registry-mirrors, like this: "registry-mirrors": ["url"],

阿里云加速器 (点击管理控制台 -> 登录账号 -> 右侧镜像中心 -> 镜像加速器 -> 复制地址);userCode=8lx5zmtu



由于镜像服务可能出现宕机,建议同时配置多个镜像。各个镜像站测试结果请到 docker-practice/docker-registry-cn-mirror-test 查看。

Configure Docker To Start On Boot


Most current Linux distributions (RHEL, CentOS, Fedora, Debian, Ubuntu 16.04 and higher) use systemd to manage which services start when the system boots. On Debian and Ubuntu, the Docker service is configured to start on boot by default. To automatically start Docker and Containerd on boot for other distros, use the commands below:

$ sudo systemctl enable docker.service
$ sudo systemctl enable containerd.service

To disable this behavior, use disable instead.

$ sudo systemctl dsiable docker.service
$ sudo systemctl disable containerd.service

Docker Pull EOF

error log:

Unable to find image 'algolia/docsearch-scraper:latest' locally
latest: Pulling from algolia/docsearch-scraper
f08d8e2a3ba1: Downloading [=>                                                 ]  560.3kB/26.7MB
3baa9cb2483b: Downloading [>                                                  ]     422B/35.36kB
94e5ff4c0b15: Download complete
1860925334f9: Download complete
docker: error pulling image configuration: Get <>: EOF.
See 'docker run --help'.

Get advice from

This was mainly because of weak network. Configured the docker daemon to reduce the tcp packets

dockerd --max-concurrent-downloads <int>

here suggests the number of docker pull layers you want to download concurrently(default is 3)

For me:

I run the order again, it didn’t display this error.

Install Docker Compose On Ubuntu

sudo curl -L "<>-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose --version
# docker-compose version 1.28.6, build 5db8d86f


Install Docker On Ubuntu

sudo apt-get remove docker docker-engine containerd runc
sudo apt-get update
sudo apt-get install \

      apt-transport-https \
      ca-certificates \
      curl \
      gnupg \

curl -fsSL <> | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg

# for x86_64/amd64
echo \

   "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] \
   $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli
sudo docker run hello-world



MX Linux

docker volume create portainer_data
docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce


docker volume create portainer_data
docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce


Manage Docker As A Non-root User

sudo groupadd docker
sudo usermod -aG docker $USER # sudo usermod -aG docker tianheg
newgrp docker
docker run hello-world



debconf: delaying package configuration, since apt-utils is not installed

RUN apt-get update && apt-get install -y --no-install-recommends apt-utils

Can’t solve it.



  2. <>