File tree Expand file tree Collapse file tree 2 files changed +40
-8
lines changed
Expand file tree Collapse file tree 2 files changed +40
-8
lines changed Original file line number Diff line number Diff line change 1+ name : Publish Docker image
2+
3+ on :
4+ push :
5+ branches : [ master ]
6+ pull_request :
7+ branches : [ master ]
8+ release :
9+ types : [published]
10+
11+ jobs :
12+ push_to_registries :
13+ runs-on : ubuntu-latest
14+ permissions :
15+ packages : write
16+ contents : read
17+ steps :
18+ - name : Check out the repo
19+ uses : actions/checkout@v2
20+
21+ - name : Log in to the Container registry
22+ uses : docker/login-action@v1.10.0
23+ with :
24+ registry : ghcr.io
25+ username : ${{ github.actor }}
26+ password : ${{ secrets.GITHUB_TOKEN }}
27+
28+ - name : Extract metadata (tags, labels) for Docker
29+ id : meta
30+ uses : docker/metadata-action@v3.5.0
31+ with :
32+ images : ghcr.io/${{ github.repository }}
33+
34+ - name : Build and push Docker images
35+ uses : docker/build-push-action@v2.7.0
36+ with :
37+ context : .
38+ push : true
39+ tags : ${{ steps.meta.outputs.tags }}
40+ labels : ${{ steps.meta.outputs.labels }}
Original file line number Diff line number Diff line change 2323
2424 - name : Test
2525 run : go test -v ./...
26-
27- docker :
28- runs-on : ubuntu-latest
29- steps :
30- - uses : actions/checkout@v2
31-
32- - name : Build
33- run : docker build .
You can’t perform that action at this time.
0 commit comments