File tree Expand file tree Collapse file tree 2 files changed +34
-41
lines changed Expand file tree Collapse file tree 2 files changed +34
-41
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ name : Release
2
+ on :
3
+ push :
4
+ branches :
5
+ - main
6
+ jobs :
7
+ build-tag-release :
8
+ name : Build, tag, and release Docker image
9
+ runs-on : ubuntu-latest
10
+ steps :
11
+ - name : Checkout repository
12
+ uses : actions/checkout@v2
13
+ - name : Setup release please
14
+ uses :
google-github-actions/[email protected]
15
+ id : release
16
+ with :
17
+ token : ${{ secrets.GITHUB_TOKEN }}
18
+ release-type : simple
19
+ changelog-path : docs/changelog.md
20
+ package-name : streetmerchant
21
+ - name : Login into GitHub Container Registry
22
+ if : ${{ steps.release.outputs.release_created }}
23
+ run : echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u $GITHUB_ACTOR --password-stdin
24
+ - name : Build Docker image
25
+ if : ${{ steps.release.outputs.release_created }}
26
+ run : |
27
+ docker build \
28
+ -t "ghcr.io/${GITHUB_REPOSITORY}:${TAG_NAME}" \
29
+ -t "ghcr.io/${GITHUB_REPOSITORY}:latest" .
30
+ env :
31
+ TAG_NAME : ${{ steps.release.outputs.tag_name }}
32
+ - name : Release Docker image
33
+ if : ${{ steps.release.outputs.release_created }}
34
+ run : docker push "ghcr.io/${GITHUB_REPOSITORY}"
You can’t perform that action at this time.
0 commit comments