File tree Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Original file line number Diff line number Diff line change 1+ name : release
2+
3+ on :
4+ push :
5+ branches :
6+ - master
7+ tags :
8+ - v*
9+
10+ jobs :
11+ build :
12+ runs-on : ubuntu-latest
13+ steps :
14+ - name : Checkout
15+ uses : actions/checkout@v2
16+ - name : setup go environment
17+ uses : actions/setup-go@v1
18+ with :
19+ go-version : ' 1.15.6'
20+ - name : Prepare
21+ id : prepare
22+ run : |
23+ VERSION=${GITHUB_REF#refs/*/}
24+ BRANCH_NAME=${GITHUB_REF#refs/heads/}
25+ if [[ "${VERSION}" == "${BRANCH_NAME}" ]]; then
26+ VERSION=$(git rev-parse --short HEAD)
27+ fi
28+ echo ::set-output name=version::${VERSION}
29+ echo ::set-output name=ref::ghcr.io/${{ github.repository }}/conformance:${VERSION}
30+ - name : Docker Build
31+ run : |
32+ docker build \
33+ --build-arg VERSION=${{ steps.prepare.outputs.version }} \
34+ -t ${{ steps.prepare.outputs.ref }} \
35+ conformance/
36+ - name : Docker Login
37+ uses : docker/login-action@v1
38+ with :
39+ registry : ghcr.io
40+ username : ${{ secrets.GHCR_USER }}
41+ password : ${{ secrets.GHCR_TOKEN }}
42+ - name : Docker Push
43+ run : |
44+ docker push ${{ steps.prepare.outputs.ref }}
45+ - name : Clear
46+ if : always()
47+ run : |
48+ rm -f ${HOME}/.docker/config.json
Original file line number Diff line number Diff line change @@ -8,4 +8,5 @@ inputs: {}
88outputs : {}
99runs :
1010 using : docker
11+ # TODO: change to "docker://ghcr.io/opencontainers/distribution-spec/conformance:<TAG>"
1112 image : conformance/Dockerfile
You can’t perform that action at this time.
0 commit comments