----- Original Message -----
From: "Heiko W.Rupp" <hrupp(a)redhat.com>
To: "Discussions around Hawkular development"
<hawkular-dev(a)lists.jboss.org>
Sent: Wednesday, 1 February, 2017 7:19:34 AM
Subject: Re: [Hawkular-dev] Docker image size does matter
On 1 Feb 2017, at 12:29, Jiri Kremser wrote:
> base image with JRE 8 and Alpine linux: 76.8 MB
Yes, alpine is only 3-4 MB that is great.
Please also take into consideration that minimal docker images do not contain common
commands and can be a pain if you need to go into the container and run commands.
Trying to debug issues when you don't have access to basic commands can be a bit
frustrating. Especially if you are not root and cannot just install binaries in the
container.
> I also removed
> 9.2M /opt/jboss/wildfly/docs
Makes sense.
> What also helped was squashing all the image layers into 1. This makes
> the
> download faster and possibly the image smaller. When applying
> docker-squash
> [1] to the current h-services image it saves ~50megs
This is a bit of a false friend as docker pull only transfers layers it
does not yet have.
E.g
$ docker pull pilhuhn/hawkular-services:0.30.0.Final
0.30.0.Final: Pulling from pilhuhn/hawkular-services
08d48e6f1cff: Already exists
664e6a3041e6: Already exists
2f8461e7022b: Already exists
9500f4548bd3: Already exists
69e2e5217a47: Already exists
cf95509fd4ad: Downloading [======>
] 10.75 MB/89.61 MB
So what you say is true for the first download, but afterwards all
the base layers of wf + jdk + ... are present. With stripping
into 1 layer there is no chance of caching.
Situation of course changes when the base layer is updated
> I am aware that this probably wont fly with some RH policy that we
> should
> base our SW on Fedora/RHEL base OS images, but I am gonna use them for
> development and because I often run out of space because of Docker.
I like those alpine images and use them for private stuff,
but for Hawkular upstream I think we should use something
that is close for downstream so minimise the moving parts.
_______________________________________________
hawkular-dev mailing list
hawkular-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hawkular-dev