From dd48296eddb047c9835b768137b850734add5979 Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Wed, 4 Oct 2023 08:32:34 -0700 Subject: [PATCH] Fix python-builder container image system updates There was a small issue in the recent change to perform system updates when building the python-builder and python-base images. I didn't realize that python-builder is a two stage build and we need to do the update in both stages. Ultimately this has minimal impact on the final images we produce as those are all build on python-base not python-builder. But to ensure some difference during python wheel build time on builder doesn't affect the install location on the base image we should keep these in sync. Change-Id: I16159fbb490b0ec2e179381a50b9570c9aacd18f --- docker/python-base/Dockerfile | 2 +- docker/python-builder/Dockerfile | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/docker/python-base/Dockerfile b/docker/python-base/Dockerfile index df24c5c0e9..636773db5b 100644 --- a/docker/python-base/Dockerfile +++ b/docker/python-base/Dockerfile @@ -13,7 +13,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Comment to force rebuilds Tue Oct 3 04:19:33 PM PDT 2023 +# Comment to force rebuilds Wed Oct 4 03:32:07 PM UTC 2023 ARG PYTHON_VERSION=3.11 ARG DEBIAN_VERSION=bullseye diff --git a/docker/python-builder/Dockerfile b/docker/python-builder/Dockerfile index a2b36cfa92..1a29a7ad34 100644 --- a/docker/python-builder/Dockerfile +++ b/docker/python-builder/Dockerfile @@ -13,7 +13,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Comment to force rebuilds Tue Oct 3 04:19:33 PM PDT 2023 +# Comment to force rebuilds Wed Oct 4 03:32:07 PM UTC 2023 ARG PYTHON_VERSION=3.11 ARG DEBIAN_VERSION=bullseye @@ -38,7 +38,9 @@ COPY --from=fake-python /tmp/python3-dev_4.0.0_all.deb /tmp/python3-dev_4.0.0_al COPY scripts/assemble /usr/local/bin/assemble COPY scripts/get-extras-packages /usr/local/bin/get-extras-packages COPY scripts/install-from-bindep /output/install-from-bindep -RUN dpkg -i /tmp/python3-dev_4.0.0_all.deb \ +RUN apt-get update \ + && apt-get dist-upgrade -y \ + && dpkg -i /tmp/python3-dev_4.0.0_all.deb \ && rm /tmp/python3-dev_4.0.0_all.deb \ && pip install --no-cache-dir bindep \ && rm -rf /var/lib/apt/lists/* \