Use --locked over --frozen in production Docker image

https://github.com/astral-sh/uv-docker-example/pull/53
This commit is contained in:
Bruno Alla 2025-09-07 13:35:42 +01:00
parent ff9ad66afc
commit 0586999b4d

View File

@ -44,7 +44,7 @@ RUN apt-get update && apt-get install --no-install-recommends -y \
RUN --mount=type=cache,target=/root/.cache/uv \
--mount=type=bind,source=uv.lock,target=uv.lock \
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
uv sync --frozen --no-install-project --no-dev
uv sync --locked --no-install-project --no-dev
{%- if cookiecutter.frontend_pipeline in ['Gulp', 'Webpack'] %}
COPY --from=client-builder ${APP_HOME} ${APP_HOME}
{% else %}
@ -54,7 +54,7 @@ COPY . ${APP_HOME}
RUN --mount=type=cache,target=/root/.cache/uv \
--mount=type=bind,source=uv.lock,target=uv.lock \
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
uv sync --frozen --no-dev
uv sync --locked --no-dev
# Python 'run' stage
FROM python:3.12-slim-bookworm AS python-run-stage