-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
35 lines (24 loc) · 925 Bytes
/
Dockerfile
File metadata and controls
35 lines (24 loc) · 925 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
32
33
34
# Base image: Python 3.12 + uv preinstalled (Debian slim)
FROM ghcr.io/astral-sh/uv:python3.12-bookworm-slim
# Environment variables
ENV UV_NO_DEV=1
ENV VENV=/env
# Work directory inside the container
WORKDIR /cli
# Install git so we can clone the repo
RUN apt-get update \
&& apt-get install -y --no-install-recommends git \
&& rm -rf /var/lib/apt/lists/*
# Copy the project files (from GitHub Actions checkout context)
COPY . .
# Install the project according to pyproject.toml + uv.lock
# --locked asserts that uv.lock is in sync with pyproject.toml
RUN uv sync
# Create separate venv for csvkit to avoid dependency conflicts
RUN uv venv $VENV --python 3.12 && \
uv pip install --python $VENV/bin/python csvkit duckdb-cli
# Put the project venv on PATH so `h5ad` is directly runnable
ENV PATH="/cli/.venv/bin:${VENV}/bin:${PATH}"
# Default entrypoint: run the CLI
ENTRYPOINT ["h5ad"]
CMD ["--help"]