Ali cloud accelerator configuration docker

1. Install / Upgrade Docker client

Recommended installation 1.10.0 or later Docker client, refer to the documentation  docker-ce

2. Configure mirroring accelerator

Docker for the user of the client version greater than 1.10.0

You can modify the daemon configuration file /etc/docker/daemon.json to use accelerator

sudo mkdir -p /etc/docker
sudo tee /etc/docker/daemon.json <<-'EOF'
{
  "registry-mirrors": ["https://aiyf7r3a.mirror.aliyuncs.com"]
}
EOF
sudo systemctl daemon-reload
sudo systemctl restart docker


另:

1. Log Ali Developer Platform

https://promotion.aliyun.com/ntms/act/kubernetes.html#industry

2. Click the "image search"

Automatically jump to a mirrored console search

3. Register / Login later

Docker image into the warehouse (https://cr.console.aliyun.com/#/imageList), select the accelerator Tab

Here you can see, the system has generated a dedicated accelerator for our address: https: //xxxxx.mirror.aliyuncs.com

The individual needs

Docker choose to run the OS, in accordance with the requirements of Docker modify configuration files, OS I have here is CentOS ,, so the following steps:

Modify the configuration file: vim usr / lib / systemd / system / docker.service

Add the red part to the back of "mirror"

ExecStart=/usr/bin/dockerd --registry-mirror=your accelerate address

Save the file and reload the preparation: $ systemctl daemon-reload

Restart the service: $ service docker restart

Verification, in a MySQL Docker client above Pull, see how speed

Guess you like

Origin www.cnblogs.com/surplus/p/11370090.html