'Does compressing files in a docker image speed up pulling it?
I have a file that's 3GB compressed, 10GB uncompressed.
Is it faster to pull an image containing only that file if the file is compressed? Or are docker images compressed already, such that compressing it won't make a difference?
Solution 1:[1]
docker images are compressed by default. you will notice when running docker pull, where it will download the needed images\layers and then extract\decompress them.
there is no need for you to compress the files within your docker images.
from the official docs:
Progress bars are shown during docker push, which show the uncompressed size. The actual amount of data that’s pushed will be compressed before sending, so the uploaded size will not be reflected by the progress bar.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 |
