Rate This Document
Findability
Accuracy
Completeness
Readability

Changing the Image Source

If you cannot pull images from dockerhub.io, you are advised to configure the Docker image accelerator in advance and use other image sources to download the required Docker images.

To change the image source, perform the following steps:

  1. Create a Docker configuration file.
    sudo mkdir -p /etc/docker
    sudo vi /etc/docker/daemon.json
  2. Press i to enter the insert mode. In the opened configuration file, add (or modify) the registry-mirrors field. Replace https://<docker-mirror> with the actual image acceleration address.
    {
    "registry-mirrors" : ["https://<docker-mirror>"]
    }
  3. Press Esc, type :wq!, and press Enter to save the file and exit.
  4. Reload the Docker configuration for the modification to take effect.
    sudo systemctl daemon-reload
    sudo systemctl restart docker