From 01b07d1838edf27dce28184aebe16c3a334ab855 Mon Sep 17 00:00:00 2001 From: Rainer Rillke Date: Sun, 15 Oct 2017 14:57:45 +0200 Subject: [PATCH] Get rid of unnecessary layers by bulk-adding files The `COPY` instruction allows adding multiple files at once. Especially for those small scripts there is no real need for multiple `COPY`/`ADD` instructions (and caching) causing the creation of an additional layer for each of them. --- Dockerfile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9c1c0d2..d4563b7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,11 +28,7 @@ RUN mkdir -p /etc/spamassassin/sa-update-keys && \ RUN sed -i 's/^logfile = .*$/logfile = \/dev\/stderr/g' /etc/razor/razor-agent.conf -COPY spamd.sh / - -COPY rule-update.sh / - -COPY run.sh / +COPY spamd.sh rule-update.sh run.sh / EXPOSE 783