-
Notifications
You must be signed in to change notification settings - Fork 25k
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
Reduce default Docker image size in 7.x #75079
Conversation
The `centos:8` image hasn't been updated for a while, and now the image layer for updating it via `yum` is larger than the base image. Address this by adopting the strategy for 8.0, where we build a custom base image from `centos:8` and use that instead. The implementation here differs in that `yum` is still available in the custom image, making it more like the CentOS image. This work saves roughly 200MB.
Pinging @elastic/es-delivery (Team:Delivery) |
Also FYI @mieciu |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A non-binding LGTM from my side 🙃 Thanks for the heads up!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Is basically the only difference between 7.x
and master
now is that the former additionally includes yum
?
@mark-vieira Kind of - we don't build a static |
@mieciu I've merged this PR, can you confirm that I haven't broken Cloud? |
Closes elastic#76695. Due to a Kubernetes quirk, we need to ensure that the `tar` CLI tool is present in the Docker image. It was removed in elastic#75079 because we reworked how the image was built, and anything not explicitly installed was left out.
The
centos:8
image hasn't been updated for a while, and now the imagelayer for updating it via
yum
is larger than the base image. Addressthis by adopting the strategy for 8.0, where we build a custom base
image from
centos:8
and use that instead. The implementation herediffers in that
yum
is still available in the custom image, making itmore like the CentOS image, and therefore less breaking than the 8.0
changes.
Before: 1.04GB
After: 806MB