From 297961003ba298a3dc2a20dc09c5b571c7ae51af Mon Sep 17 00:00:00 2001 From: Mark Hansen Date: Sun, 14 Feb 2021 16:51:42 +1100 Subject: [PATCH] Smoosh some Dockerfile layers into one This is kind of a test for the new automatic building of dockerfiles. This should make for smaller images and slightly faster CI runs. The tradeoff is slower local builds if you'd cached the earlier bits. But now we can easily build these on the cloud when changed. --- ci/centos7/Dockerfile | 13 +++++-------- ci/centos8/Dockerfile | 7 +++---- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/ci/centos7/Dockerfile b/ci/centos7/Dockerfile index 265a81fa9..216ce1f50 100644 --- a/ci/centos7/Dockerfile +++ b/ci/centos7/Dockerfile @@ -1,20 +1,17 @@ FROM centos:7 # Development tools -RUN yum -y groupinstall 'Development Tools' - -RUN yum install -y \ +RUN yum -y groupinstall 'Development Tools' \ +&& yum install -y \ # Install epel-release rpm (Needed for cmake3. Must be a separate step) https://download-ib01.fedoraproject.org/pub/epel/7/x86_64/Packages/e/epel-release-7-12.noarch.rpm \ # Install ius-release rpm (Needed for git version 2. Must be a separate step) https://repo.ius.io/ius-release-el7.rpm \ -&& yum clean all && rm -rf /var/cache/yum - +&& yum clean all && rm -rf /var/cache/yum \ # Remove old version of git -RUN yum -y remove git - +&& yum -y remove git \ # Centos build utilities -RUN yum -y install \ +&& yum -y install \ libtool-ltdl-devel \ libedit-devel \ ksh \ diff --git a/ci/centos8/Dockerfile b/ci/centos8/Dockerfile index f658bd7ca..41651743a 100644 --- a/ci/centos8/Dockerfile +++ b/ci/centos8/Dockerfile @@ -1,11 +1,10 @@ FROM centos:8 # Development tools -RUN yum -y groupinstall 'Development Tools' -RUN dnf config-manager --set-enabled powertools - +RUN yum -y groupinstall 'Development Tools' \ +&& dnf config-manager --set-enabled powertools \ # Centos build utilities -RUN yum -y install \ +&& yum -y install \ libtool-ltdl-devel \ libedit-devel \ ksh \ -- 2.40.0