Docker replacement for domestic mirrors

Source: Internet
Author: User
Tags documentation
Reason for replacement

The official mirror of Docker's visit to the country has been slow as a snail. In order to quickly access Docker official image will be configured with three-side accelerator, the current common three-party accelerator: NetEase, USTC, Daocloud, Aliyun.

Now Docker has launched a mirror-acceleration service for the Chinese region. With Docker official image acceleration, domestic users are able to access the most popular Docker mirrors with faster download speeds and greater stability. How to use official mirrors

Docker China official image acceleration can be accessed through registry.docker-cn.com. The Mirror library currently contains only popular public mirrors, while private mirrors still need to be pulled from the US mirror library.

You can use the following command to pull directly from the mirrored acceleration address.

Docker Pull Registry.docker-cn.com/myname/myrepo:mytag

Examples are as follows:

Docker Pull registry.docker-cn.com/library/ubuntu:16.04

Note: Unless you modify the –registry-mirror parameters of the Docker daemon, you will need to fully specify the name of the official mirror. For example, Library/ubuntu, Library/redis, Library/nginx. configuring accelerators for the Docker daemon

Start Docker with the configuration file, modify the/etc/docker/daemon.json file, and add the Registry-mirrors key value.

sudo vim/etc/docker/daemon.json
{
 ' registry-mirrors ': [' https://registry.docker-cn.com ']
}

Also can choose NetEase's Mirror address: http://hub-mirror.c.163.com

{
"Registry-mirrors": ["http://hub-mirror.c.163.com"]
}

After modifying the save, restart the Docker for the configuration to take effect.

sudo service docker restart

Then the speed went up a step.

Reference Documentation:
Docker documentation
Docker Domestic mirror source settings
Docker change the official mirror of the country
Configuring the official domestic speed mirror for Docker

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.