Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ jobs:
run: |
VERSION="${TAG#v}"
make build-docker \
VERSION="$VERSION" \
DOCKER_REGISTRY="ghcr.io/${{ github.repository_owner }}" \
DOCKER_TAG="$VERSION"
env:
Expand Down
7 changes: 7 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@ COPY src ./src

COPY --from=ui /build/ui/dist ./src/agentevals/_static

# hatch-vcs reads the version from .git, which the docker build context omits.
# Pass it in as a build arg. We use the generic SETUPTOOLS_SCM_PRETEND_VERSION
# because hatch-vcs does not forward dist_name to setuptools-scm, so the
# per-package SETUPTOOLS_SCM_PRETEND_VERSION_FOR_<DIST> form is never consulted.
ARG VERSION
ENV SETUPTOOLS_SCM_PRETEND_VERSION=${VERSION}

RUN uv sync --frozen --no-dev --extra live --extra postgres \
&& groupadd --gid 1000 app \
&& useradd --uid 1000 --gid app --home-dir /app --no-log-init app \
Expand Down
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ build:
uv build

build-docker:
docker buildx build --platform $(PLATFORMS) -t $(DOCKER_IMAGE_REF):$(DOCKER_TAG) --push .
@test -n "$(VERSION)" || { echo "ERROR: VERSION is empty. Pass VERSION=x.y.z explicitly, or install uv so hatch-vcs can resolve it."; exit 1; }
docker buildx build --platform $(PLATFORMS) --build-arg VERSION=$(VERSION) -t $(DOCKER_IMAGE_REF):$(DOCKER_TAG) --push .

build-ui:
cd ui && npm ci && npm run build
Expand Down
Loading