File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Build and push Docker image
2+ on :
3+ release :
4+ types : [published]
5+ workflow_dispatch :
6+ jobs :
7+ dockerize :
8+ name : Build and push to GHCR
9+ runs-on : ubuntu-latest
10+ permissions :
11+ contents : read
12+ packages : write
13+ steps :
14+ - uses : actions/checkout@v6
15+ - name : Build image
16+ run : |
17+ buildah build \
18+ -t ghcr.io/${{ github.repository }}:$GITHUB_REF_NAME \
19+ -t ghcr.io/${{ github.repository }}:latest .
20+ - name : Push image
21+ run : |
22+ buildah login -u ${{ github.actor }} -p ${{ secrets.GITHUB_TOKEN }} ghcr.io
23+ buildah push ghcr.io/${{ github.repository }}:$GITHUB_REF_NAME
24+ buildah push ghcr.io/${{ github.repository }}:latest
Original file line number Diff line number Diff line change 1- FROM python:3.13-slim-bookworm
1+ FROM ghcr.io/astral-sh/uv:python3.14-trixie-slim AS builder
22
33WORKDIR /app
44COPY . .
5- RUN pip install . && pip cache purge && rm -rf /app/*
5+ RUN uv build
6+
7+ FROM python:3.14-slim-trixie
8+
9+ COPY --from=builder /app/dist/*.whl /tmp/
10+ RUN pip install --no-cache-dir /tmp/*.whl && rm /tmp/*.whl
611
712ENTRYPOINT ["crpy" ]
13+ CMD ["--help" ]
You can’t perform that action at this time.
0 commit comments