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+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+
8+ jobs :
9+ build-and-push :
10+ runs-on : ubuntu-latest
11+ permissions :
12+ contents : read
13+ packages : write
14+
15+ steps :
16+ - name : Checkout
17+ uses : actions/checkout@v4
18+
19+ - name : Log in to GitHub Container Registry
20+ uses : docker/login-action@v3
21+ with :
22+ registry : ghcr.io
23+ username : ${{ github.actor }}
24+ password : ${{ secrets.GITHUB_TOKEN }}
25+
26+ - name : Extract version from tag
27+ id : meta
28+ uses : docker/metadata-action@v5
29+ with :
30+ images : ghcr.io/${{ github.repository_owner }}/blimmp
31+ tags : |
32+ type=semver,pattern={{version}}
33+ type=semver,pattern={{major}}.{{minor}}
34+ type=raw,value=latest
35+
36+ - name : Build and push
37+ uses : docker/build-push-action@v5
38+ with :
39+ context : .
40+ push : true
41+ tags : ${{ steps.meta.outputs.tags }}
Original file line number Diff line number Diff line change 1+ FROM python:3.10-slim
2+
3+ WORKDIR /app
4+ COPY . .
5+ RUN pip install --no-cache-dir .
You can’t perform that action at this time.
0 commit comments