[Dockerfiles] Used best practices for apt-get
See https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/#apt-get - Replaced `-y install` with `install -y` (unification) - Put every package on its own line - Moved `rm -rf /var/lib/apt/lists/*` in the same `RUN` statement as `apt-get` - Removed unnecessary `apt-get clean` See https://github.com/moby/moby/blob/03e2923e42446dbb830c654d0eec323a0b4ef02a/contrib/mkimage/debootstrap#L82-L105
This commit is contained in:
@@ -8,14 +8,12 @@ ENV DEBIAN_VERSION stretch
|
||||
RUN echo "deb http://http.debian.net/debian/ $DEBIAN_VERSION main contrib non-free" > /etc/apt/sources.list && \
|
||||
echo "deb http://http.debian.net/debian/ $DEBIAN_VERSION-updates main contrib non-free" >> /etc/apt/sources.list && \
|
||||
echo "deb http://security.debian.org/ $DEBIAN_VERSION/updates main contrib non-free" >> /etc/apt/sources.list && \
|
||||
apt-get update && \
|
||||
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y -qq \
|
||||
apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y -qq --no-install-recommends \
|
||||
clamav-daemon \
|
||||
clamav-freshclam \
|
||||
libclamunrar7 \
|
||||
curl && \
|
||||
apt-get clean && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
curl \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# initial update of av databases
|
||||
COPY dl_files.sh /dl_files.sh
|
||||
|
||||
Reference in New Issue
Block a user