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 Image CD
2+
3+ on :
4+ push :
5+ branches : [ master, develop ]
6+ jobs :
7+ build :
8+ runs-on : ubuntu-latest
9+ steps :
10+ - uses : actions/checkout@v3
11+ - name : Set up Python
12+ uses : actions/setup-python@v3
13+ with :
14+ python-version : " 3.9"
15+ - name : GithubPackages Login
16+ uses : docker/login-action@v1.10.0
17+ with :
18+ registry : ghcr.io
19+ username : ${{ github.actor }}
20+ password : ${{ secrets.GITHUB_TOKEN }}
21+ - name : Extract metadata (tags, labels) for Docker
22+ id : meta
23+ uses : docker/metadata-action@v3
24+ with :
25+ images : ghcr.io/${{ github.repository }}
26+ - name : Build and push Docker images
27+ if : github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop'
28+ uses : docker/build-push-action@v2
29+ with :
30+ context : .
31+ push : true
32+ tags : ${{ steps.meta.outputs.tags }}
33+ labels : ${{ steps.meta.outputs.labels }}
You can’t perform that action at this time.
0 commit comments