yum clean all
after yum install
DOK-P1000Not cleaning cached package data after installation can result in higher image sizes. It is always recommended to clean the cached packages after installing them.
Please note that the clean-up must be performed in the same RUN
step as it creates a separate layer. Doing this in a separate RUN
command would therefore result in a new layer, which will not help reduce the image size.
RUN yum install -y httpd-2.24.2
RUN yum install -y httpd-2.24.2 && yum clean all