-
Notifications
You must be signed in to change notification settings - Fork 18.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[public repo] images should use high compression #194
Comments
While we're at it, we might as well enable high compression whenever docker creates a tarball. Eg. 'docker push' and 'docker export'. |
Using higher compression for all operations which create tarballs would be really nice. The return is quite significant over time when it comes to the amount of storage needed on S3 and the network traffic. I think only these changes are required to start using high compression for all new images on the registry:
|
Don't use bzip2: use lzma/xz instead. See e.g. http://pokecraft.first-world.info/wiki/Quick_Benchmark:_Gzip_vs_Bzip2_vs_LZMA_vs_XZ_vs_LZ4_vs_LZO Also, I couldn't check in the source, but we should obviously make sure that the layer hash is done on the uncompressed tar. |
There is no layer hash right now, image IDs are computed randomly. I want On Sunday, March 31, 2013, Jérôme Petazzoni wrote:
|
I've done some tests with the pybuilder image:
The xz lzma2 compressed image is 14% smaller than the bzip2 compressed image. Other images show a similar decrease in size. Some even go down to 30% of the original size. |
Note: we would also have to update docker dependencies and installation instructions to tell people to install Bonus points if docker makes sure that |
The extra dependency is definitely a -1. Is it really worth the trouble compared to bzip2 -9? |
xz isn't required. bsdtar has native support for xz compression and it doesn't need xz from xz-utils, nor anything else. I've just verified this by using bsdtar to compress in xz format, ran xz to make sure it's not there and then installed xz-utils to extract the archive. Everything worked. So there's really nothing to warn about, other than about bsdtar's absence. |
Awesome. On Mon, Apr 1, 2013 at 10:26 AM, unclejack notifications@github.com wrote:
|
If we want to drop the bsdtar dependency we can. Just swap in |
archive/tar doesn't support actual tarring and untarring on the filesystem. There is also auto-detection of compression which is a really useful On Monday, April 1, 2013, Jonathan Rudenberg wrote:
|
@shykes Yeah, it would require essentially reimplementing the file walking and tar header building that tar/bsdtar does. |
Backport pulldigests fedora
use /etc/init.d/jenkins variant to provide multiple java options with quotes
…nerd_v1.2.6 [18.09 backport] Bump containerd v1.2.6, runc v1.0.0-rc8
The images from the public repository should be using bzip2 -9 compression to speed up downloads and reduce traffic.
gzip compressed image:
pybuilder 288 MB
bzip2 -9 compressed image:
pybuilder.bz2 268 MB
savings: 20 MB, about 7%
The text was updated successfully, but these errors were encountered: