This repository was archived by the owner on Oct 21, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +32
-18
lines changed
Expand file tree Collapse file tree 2 files changed +32
-18
lines changed Original file line number Diff line number Diff line change 1+ name : CD
2+
3+ on :
4+ release :
5+ types : [released]
6+
7+ jobs :
8+ test :
9+ uses : ./.github/workflows/test.yml
10+ docker :
11+ needs : test
12+ runs-on : ubuntu-latest
13+ name : " Build Docker image and push to Docker Hub"
14+ steps :
15+ - name : Get version string
16+ id : get-version
17+ run : |
18+ tag=${{github.event.release.tag_name}}
19+ echo "::set-output name=version::${tag:1}"
20+ - uses : actions/checkout@v2
21+ - name : Set up Docker Buildx
22+ uses : docker/setup-buildx-action@v2
23+ - name : Login to DockerHub
24+ uses : docker/login-action@v2
25+ with :
26+ username : ${{ secrets.DOCKERHUB_USERNAME }}
27+ password : ${{ secrets.DOCKERHUB_TOKEN }}
28+ - name : Build and push
29+ uses : docker/build-push-action@v3
30+ with :
31+ push : true
32+ tags : ppodds/ncuplus-backend:latest,ppodds/ncuplus-backend:${{ steps.get-version.outputs.version }}
Original file line number Diff line number Diff line change 77jobs :
88 test :
99 uses : ./.github/workflows/test.yml
10- docker :
11- needs : test
12- runs-on : ubuntu-latest
13- name : " Build Docker image and push to Docker Hub"
14- steps :
15- - uses : actions/checkout@v2
16- - name : Set up Docker Buildx
17- uses : docker/setup-buildx-action@v2
18- - name : Login to DockerHub
19- uses : docker/login-action@v2
20- with :
21- username : ${{ secrets.DOCKERHUB_USERNAME }}
22- password : ${{ secrets.DOCKERHUB_TOKEN }}
23- - name : Build and push
24- uses : docker/build-push-action@v3
25- with :
26- push : true
27- tags : ppodds/ncuplus-backend:latest
You can’t perform that action at this time.
0 commit comments