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 : Docker Build & Push
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ tags :
8+ - " v*.*.*"
9+
10+ jobs :
11+ build-and-push :
12+ name : Build & Push Docker Image
13+ runs-on : ubuntu-latest
14+
15+ steps :
16+ - uses : actions/checkout@v4
17+ with :
18+ submodules : recursive
19+
20+ - uses : docker/setup-buildx-action@v3
21+
22+ - uses : docker/login-action@v3
23+ with :
24+ username : ${{ github.repository_owner }}
25+ password : ${{ secrets.DOCKERHUB_TOKEN }}
26+
27+ - name : Build and push latest (main branch only)
28+ if : github.ref == 'refs/heads/main'
29+ uses : docker/build-push-action@v6
30+ with :
31+ context : .
32+ platforms : &platforms linux/amd64,linux/arm64
33+ push : true
34+ tags : ${{ github.repository }}:latest
35+
36+ - name : Build and push semver tag (tags only)
37+ if : startsWith(github.ref, 'refs/tags/v')
38+ uses : docker/build-push-action@v6
39+ with :
40+ context : .
41+ platforms : *platforms
42+ push : true
43+ tags : ${{ github.repository }}:${{ github.ref_name }}
Original file line number Diff line number Diff line change 1+ FROM python:3-alpine
2+ RUN apk add git nodejs npm
3+ && pip install --no-cache-dir pylint isort gitlint flake8==5.0.4 flake8-typing-imports flake8-quotes
4+ && npm install -g markdownlint-cli htmlhint
5+ WORKDIR /workspace
6+ CMD ["/bin/sh" ]
You can’t perform that action at this time.
0 commit comments