From 559d9dda719f44a7c67ddb329a0719cb57b1c600 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20K=C3=A4ufl?= Date: Sat, 13 May 2017 16:11:04 +0200 Subject: [PATCH] [Dockerfiles] Run rm as early as possible --- data/Dockerfiles/dovecot/Dockerfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/data/Dockerfiles/dovecot/Dockerfile b/data/Dockerfiles/dovecot/Dockerfile index 9664bc54..708ff8bd 100644 --- a/data/Dockerfiles/dovecot/Dockerfile +++ b/data/Dockerfiles/dovecot/Dockerfile @@ -57,14 +57,16 @@ RUN wget https://www.dovecot.org/releases/2.2/dovecot-$DOVECOT_VERSION.tar.gz -O && ./configure --with-mysql --with-lzma --with-lz4 --with-ssl=openssl --with-notify=inotify --with-storages=mdbox,sdbox,maildir,mbox,imapc,pop3c --with-bzlib --with-zlib \ && make -j3 \ && make install \ - && make clean + && make clean \ + && cd .. && rm -rf dovecot-$DOVECOT_VERSION RUN wget https://pigeonhole.dovecot.org/releases/2.2/dovecot-2.2-pigeonhole-$PIGEONHOLE_VERSION.tar.gz -O - | tar xvz \ && cd dovecot-2.2-pigeonhole-$PIGEONHOLE_VERSION \ && ./configure \ && make -j3 \ && make install \ - && make clean + && make clean \ + && cd .. && rm -rf dovecot-2.2-pigeonhole-$PIGEONHOLE_VERSION RUN cpanm Data::Uniqid Mail::IMAPClient String::Util RUN echo '* * * * * root /usr/local/bin/imapsync_cron.pl' > /etc/cron.d/imapsync @@ -103,6 +105,4 @@ CMD exec /usr/bin/supervisord -c /etc/supervisor/supervisord.conf RUN rm -rf \ /tmp/* \ - /var/tmp/* \ - /dovecot-2.2-pigeonhole-$PIGEONHOLE_VERSION \ - /dovecot-$DOVECOT_VERSION + /var/tmp/*