File tree 1 file changed +8
-10
lines changed
1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change 1
1
name : build and push image to dockerhub
2
2
on :
3
3
push :
4
- branches :
5
- - ona-custom-changes
6
- workflow_dispatch :
7
- inputs :
8
- versionTag :
9
- description : " Version Tag"
10
- required : true
11
- default : " "
4
+ tags :
5
+ - ' [0-9]+\.[0-9]+\.[0-9]+'
12
6
jobs :
13
7
main :
14
8
runs-on : ubuntu-22.04
15
9
steps :
10
+ - name : Get the version
11
+ id : get-version-release
12
+ run : echo "version=${GITHUB_REF_NAME#refs/heads}" >> $GITHUB_ENV
13
+
16
14
- name : Checkout to version
17
15
uses : actions/checkout@v3
18
16
with :
19
- ref : ${{ github.event.inputs.versionTag || '0.0.4' }}
17
+ ref : ${{ env.version }}
20
18
21
19
- name : Login to DockerHub
22
20
uses : docker/login-action@v2
32
30
file : Dockerfile
33
31
platforms : linux/amd64
34
32
tags : |
35
- onaio/dirt-tile-server:${{ github.event.inputs.versionTag || '0.0.4' }}
33
+ onaio/dirt-tile-server:${{ env.version }}
36
34
37
35
- name : Image digest
38
36
run : echo ${{ steps.docker-build.outputs.digest }}
You can’t perform that action at this time.
0 commit comments