1- # TODO: Update to official python-3.13-minimal image when available
21ARG BASE_IMAGE=quay.io/fedora/python-313-minimal:latest
32
43# Use a multi-stage build to create a lightweight production image
@@ -16,22 +15,23 @@ USER root
1615
1716# Install build tooling
1817RUN dnf install -y git \
19- && /usr/bin/python3 -m venv /tmp/pdm \
20- && /tmp/pdm /bin/pip install --no-cache-dir -U pdm \
21- && ln -s /tmp/pdm /bin/pdm /usr/local/bin/pdm
18+ && /usr/bin/python3 -m venv /tmp/uv \
19+ && /tmp/uv /bin/pip install --no-cache-dir -U uv \
20+ && ln -s /tmp/uv /bin/uv /usr/local/bin/uv
2221
23- # Disable pdm update check
22+ # Set the default venv for uv
23+ # Copy instead of link files with uv
2424# Set correct build type for versioning
25- ENV PDM_CHECK_UPDATE=false \
25+ ENV VIRTUAL_ENV=/opt/app-root \
26+ UV_LINK_MODE="copy" \
2627 GUIDELLM_BUILD_TYPE=$GUIDELLM_BUILD_TYPE
2728
2829# Copy repository files
2930# Do this as late as possible to leverage layer caching
3031COPY / /src
3132
3233# Install guidellm and locked dependencies
33- RUN pdm use -p /src -f /opt/app-root \
34- && pdm install -p /src -G all --check --prod --no-editable
34+ RUN uv sync --active --project /src --frozen --no-dev --extra all --no-editable
3535
3636# Prod image
3737FROM $BASE_IMAGE
@@ -51,7 +51,7 @@ USER 1001:0
5151# Add guidellm bin to PATH
5252# Argument defaults can be set with GUIDELLM_<ARG>
5353ENV HOME="/home/guidellm" \
54- GUIDELLM_OUTPUT_PATH ="/results/benchmarks.json "
54+ GUIDELLM_OUTPUT_DIR ="/results"
5555
5656# Create the user home dir
5757WORKDIR $HOME
0 commit comments