Skip to content
9 changes: 7 additions & 2 deletions state-manager/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
FROM python:3.12-slim-bookworm
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
ARG UV_VERSION=0.4.28
ARG UV_DIGEST=sha256:REPLACE_WITH_MANIFEST_DIGEST
FROM ghcr.io/astral-sh/uv:${UV_VERSION}@${UV_DIGEST} AS uv
ARG PYTHON_DIGEST=sha256:REPLACE_WITH_MANIFEST_DIGEST
FROM python:3.12-slim-bookworm@${PYTHON_DIGEST}

COPY --from=uv /uv /usr/local/bin/uv
Comment on lines +1 to +7

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@RaghuveeRR07 I do not understand why the earlier implementation was not working but current one is

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you please explain more ?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The earlier implementation had the latest tag due to which the manifest files for some architecture like armv7 did not exist. this was one of the error I encountered buildx error: “no match for platform in manifest”.

Manifest file is a just a JSON file, which has info about which image is suitable for which arch.

This is the only change I implemented because when I even tried pushing the image of docker hub, armv7 failed. So I understood there is need to specify the version while installing uv.

All the other changes were suggested by this codeReview bot, so I am not really sure what the "digest" tag does.


WORKDIR /api-server

Expand Down