File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change 4
4
tags :
5
5
- ' *-dev'
6
6
workflow_dispatch :
7
+ inputs :
8
+ dockerRepository :
9
+ description : ' Docker repository'
10
+ required : true
11
+ default : ' preview'
12
+ type : choice
13
+ options :
14
+ - preview
15
+ - redash
7
16
8
17
env :
9
18
NODE_VERSION : 18
75
84
# TODO: We can use GitHub Actions's matrix option to reduce the build time.
76
85
- name : Build and push preview image to Docker Hub
77
86
uses : docker/build-push-action@v4
87
+ if : ${{ github.event.inputs.dockerRepository == 'preview' || !github.event.workflow_run }}
78
88
with :
79
89
push : true
80
90
tags : |
89
99
env :
90
100
DOCKER_CONTENT_TRUST : true
91
101
102
+ - name : Build and push release image to Docker Hub
103
+ uses : docker/build-push-action@v4
104
+ if : ${{ github.event.inputs.dockerRepository == 'redash' }}
105
+ with :
106
+ push : true
107
+ tags : |
108
+ redash/redash:${{ steps.version.outputs.VERSION_TAG }}
109
+ context : .
110
+ build-args : |
111
+ test_all_deps=true
112
+ cache-from : type=gha,scope=multi-platform
113
+ cache-to : type=gha,mode=max,scope=multi-platform
114
+ platforms : linux/amd64,linux/arm64
115
+ env :
116
+ DOCKER_CONTENT_TRUST : true
117
+
92
118
- name : " Failure: output container logs to console"
93
119
if : failure()
94
120
run : docker compose logs
You can’t perform that action at this time.
0 commit comments