From 99f7a30d9585bac93f2492d36cfa057de1f68973 Mon Sep 17 00:00:00 2001 From: Gerrod Ubben Date: Mon, 27 Apr 2026 18:31:47 -0400 Subject: [PATCH] Use uv pip install on container build --- templates/github/.ci/ansible/Containerfile.j2.copy | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/templates/github/.ci/ansible/Containerfile.j2.copy b/templates/github/.ci/ansible/Containerfile.j2.copy index a446f339..13b5ff05 100644 --- a/templates/github/.ci/ansible/Containerfile.j2.copy +++ b/templates/github/.ci/ansible/Containerfile.j2.copy @@ -10,9 +10,8 @@ ADD ./{{ item.origin }} {{ item.destination }} {%- endfor %} # This MUST be the ONLY call to pip install in inside the container. -RUN pip3 install --upgrade pip setuptools wheel && \ - rm -rf /root/.cache/pip && \ - pip3 install {{ image.source }} +RUN --mount=type=cache,target=/root/.cache/uv uv pip install --upgrade setuptools wheel && \ + uv pip install {{ image.source }} {%- if image.upperbounds | default(false) -%} {{ " " }}-c ./{{ plugin_name }}/upperbounds_constraints.txt {%- endif -%} @@ -22,8 +21,7 @@ RUN pip3 install --upgrade pip setuptools wheel && \ {%- if image.ci_requirements | default(false) -%} {{ " " }}-r ./{{ plugin_name }}/ci_requirements.txt {%- endif -%} -{{ " " }}-c ./{{ plugin_name }}/.ci/assets/ci_constraints.txt && \ - rm -rf /root/.cache/pip +{{ " " }}-c ./{{ plugin_name }}/.ci/assets/ci_constraints.txt {% if pulp_env is defined and pulp_env %} {% for key, value in pulp_env.items() %}