Skip to content

Commit 078a192

Browse files
authored
iris: copy hatch_build.py into Docker images (#3650)
- Dockerfile.worker and Dockerfile.controller now `COPY hatch_build.py` alongside `pyproject.toml` so the custom hatch build hook (added in #3631) is present when `uv sync` runs during the Docker build. - Without this, the build fails with `OSError: Build script does not exist: hatch_build.py`. - Dockerfile.task is unaffected (it doesn't run `uv sync` at build time, and already has nodejs/npx for proto generation at runtime).
1 parent 3363c5b commit 078a192

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lib/iris/Dockerfile.controller

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ COPY --from=ghcr.io/astral-sh/uv:0.10.3 /uv /uvx /bin/
4242

4343
WORKDIR /app
4444

45-
# Copy pyproject.toml first and sync dependencies (cached layer)
46-
COPY pyproject.toml ./
45+
# Copy pyproject.toml and build hook first and sync dependencies (cached layer)
46+
COPY pyproject.toml hatch_build.py ./
4747
RUN uv sync --no-install-project
4848

4949
# Copy source and install the project

lib/iris/Dockerfile.worker

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,9 @@ COPY --from=ghcr.io/astral-sh/uv:0.10.3 /uv /uvx /bin/
5757

5858
WORKDIR /app
5959

60-
# Copy pyproject first so the heavy dependency install is cached
61-
# independently of source changes.
62-
COPY pyproject.toml ./
60+
# Copy pyproject and build hook first so the heavy dependency install is
61+
# cached independently of source changes.
62+
COPY pyproject.toml hatch_build.py ./
6363
RUN uv sync --no-install-project
6464

6565
# Copy source and install the project itself (fast, deps already installed above)

0 commit comments

Comments
 (0)