I'm adding RPMS to my docker image and installing them during the image build. I have the feeling that I have the RPMS twice in my image. At the place where I added them and at the place where RPM installed them. In total there is about 500 MB RPMS (yes they are big) and the final docker image grows from 700 MB base image to 2.1 GB final image.
Question: How can I avoid ADDing them to the image at all.
First idea I had was putting them into a local yum repository and then use yum to install from the repository. This would remove the ADDing to the docker image.
Is there any other possibility? Why can't I mound a external server volume and install the file from there?