From 17ed3f6c9a34d05843f8a11891f19aa50225fe15 Mon Sep 17 00:00:00 2001 From: Vojtech Mares Date: Sat, 10 Sep 2022 14:41:53 +0200 Subject: [PATCH] feat(Dockerfile): remove cached files from `apt update` --- Dockerfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 3bef80e..217a80e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,11 @@ RUN apt update && apt -y install \ # Add Ondrej Sury's PPA for PHP RUN LC_ALL=C.UTF-8 add-apt-repository -y ppa:ondrej/php -RUN apt update +RUN apt update && \ + rm -rf /var/lib/apt && \ + rm -rf /var/lib/dpkg && \ + rm -rf /var/lib/cache && \ + rm -rf /var/lib/log # Install PHP 8.1 RUN DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt -y install \