By default, Docker opens up multiple upload or download connections, so that it can move multiple layers of images at a given time. This is a performance boost, when used with a reliable connection. But if your network connectivity is not so reliable, doing one thing at a time and waiting for it to succeed can make sure the number of failed attempts are low, and the process completes comparatively faster.
How
- Open
/etc/docker/daemon.json(If thedaemon.jsonfile doesn’t exist in/etc/docker/, create it.). - Add following values:
{ "max-concurrent-uploads": 1, "max-concurrent-downloads": 1 } - Restart Docker Daemon:
sudo service docker restart.
One response to “Docker Limit Concurrent Uploads and Downloads: For Unreliable Network Connections”
Short and straight to the point. Thanks.