From 5d51caec30e4ac395f3bdbd7d1198803ec58301c Mon Sep 17 00:00:00 2001 From: darkwizard242 Date: Mon, 25 Mar 2024 18:53:38 -0400 Subject: [PATCH] remove EXTERNALLY-MANAGED file in python lib for installation via pip --- ubuntu-24.04/Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ubuntu-24.04/Dockerfile b/ubuntu-24.04/Dockerfile index 0b567af..a3aaa03 100644 --- a/ubuntu-24.04/Dockerfile +++ b/ubuntu-24.04/Dockerfile @@ -9,7 +9,8 @@ ENV PIP_PKGS "ansible" RUN DEBIAN_FRONTEND=non-interactive apt-get update -y \ && DEBIAN_FRONTEND=non-interactive apt-get --no-install-recommends -y upgrade \ && DEBIAN_FRONTEND=non-interactive apt-get install --no-install-recommends -y ${DEPENDENCIES} \ - && python3 -m pip install --no-cache-dir --break-system-packages -U ${PIP_PKGS} \ + && find /usr/lib/python3* -type f -name EXTERNALLY-MANAGED -exec rm -v {} \; \ + && python3 -m pip install --no-cache-dir -U ${PIP_PKGS} \ && rm -rf /var/lib/apt/lists/* /var/cache/apt/archives/*.deb \ && for FILE in $(find /var/log -maxdepth 2 -type f); do echo "" > ${FILE}; done \ && apt-get autoremove \