Skip to content

Commit b726bc6

Browse files
committed
Add missing clean up after quota-related dnf install to avoid bloating image
with package cache, etc. as pointed out by hadolint.
1 parent 4ce2159 commit b726bc6

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

Dockerfile.rocky8

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1690,6 +1690,9 @@ RUN if [ "${ENABLE_QUOTA}" = "True" ] \
16901690
libnl3-devel.x86_64 \
16911691
libyaml-devel \
16921692
krb5-devel.x86_64 \
1693+
&& dnf clean all \
1694+
&& rm -fr /var/cache/dnf \
1695+
# TODO: clean up after this download+build to avoid bloating image
16931696
&& cd ${MIG_ROOT}/mig/src/pylustrequota \
16941697
&& git clone git://git.whamcloud.com/fs/lustre-release.git \
16951698
&& cd ${MIG_ROOT}/mig/src/pylustrequota/lustre-release \

Dockerfile.rocky9

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1577,6 +1577,9 @@ RUN if [ "${ENABLE_QUOTA}" = "True" ] \
15771577
libnl3-devel.x86_64 \
15781578
libyaml-devel \
15791579
krb5-devel.x86_64 \
1580+
&& dnf clean all \
1581+
&& rm -fr /var/cache/dnf \
1582+
# TODO: clean up after this download+build to avoid bloating image
15801583
&& cd ${MIG_ROOT}/mig/src/pylustrequota \
15811584
&& git clone git://git.whamcloud.com/fs/lustre-release.git \
15821585
&& cd ${MIG_ROOT}/mig/src/pylustrequota/lustre-release \

0 commit comments

Comments
 (0)