-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathDockerfile
More file actions
31 lines (22 loc) · 878 Bytes
/
Copy pathDockerfile
File metadata and controls
31 lines (22 loc) · 878 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
FROM ubuntu:26.04 AS base
LABEL maintainer="Andrew Van <vanandrew77@gmail.com>"
ENV DEBIAN_FRONTEND=noninteractive
WORKDIR /opt
# build deps (python comes from uv)
RUN apt-get update && \
apt-get install -y build-essential cmake curl git unzip ca-certificates && \
rm -rf /var/lib/apt/lists/*
# install uv (static binary)
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /usr/local/bin/
# get and install warpkit
ADD . /opt/warpkit
# sync project (installs python 3.11, deps, and builds the CMake extension)
ENV UV_PROJECT_ENVIRONMENT=/opt/warpkit/.venv
ENV UV_PYTHON_PREFERENCE=only-managed
RUN cd /opt/warpkit && uv sync --group dev -v
# put the project venv on PATH so `wk-medic` and friends resolve
ENV PATH=/opt/warpkit/.venv/bin:${PATH}
# test warpkit
RUN cd /opt/warpkit && uv run pytest -s -v
# set wk-medic script as entrypoint
ENTRYPOINT ["wk-medic"]