-
Notifications
You must be signed in to change notification settings - Fork 14
211 lines (207 loc) · 7.68 KB
/
nodered-container.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
name: Build Node-RED container
on:
workflow_dispatch:
inputs:
nr_project_nodes_release_name:
description: 'nr-project-nodes package version'
required: false
default: 'nightly'
nr_project_nodes_ref:
description: 'nr-project-nodes package ref'
required: false
push:
branches:
- main
paths-ignore:
- 'helm/**'
- '.github/workflows/helm*'
pull_request:
branches:
- main
paths-ignore:
- 'helm/**'
- '.github/workflows/helm*'
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true
jobs:
build-302:
name: Build 3.0.2 container images
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
dockerfile_path: Dockerfile
image_tag_prefix: '3.0.2-'
package_dependencies: |
@flowforge/nr-project-nodes
build_context: 'node-red-container'
npm_registry_url: ${{ vars.PUBLIC_NPM_REGISTRY_URL }}
scan_image: true
secrets:
npm_registry_auth_token: ${{ secrets.NPM_PUBLISH_TOKEN }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
build-302-multi-architecture:
name: Build multi-architecture container image
needs: build-302
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
image_tag_prefix: '3.0.2-'
secrets:
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
upload-302-stage:
name: Upload image to staging ECR
if: github.ref_name == 'main'
needs: build-302-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: stage
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-302-multi-architecture.outputs.image }}
image_tag_prefix: '3.0.2-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}
upload-302-prod:
name: Upload image to production ECR
if: github.ref_name == 'main'
needs: build-302-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: production
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-302-multi-architecture.outputs.image }}
image_tag_prefix: '3.0.2-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}
build-223:
name: Build 2.2.3 container images
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
dockerfile_path: Dockerfile-2.2.x
image_tag_prefix: '2.2.3-'
package_dependencies: |
@flowforge/nr-project-nodes
build_context: 'node-red-container'
npm_registry_url: ${{ vars.PUBLIC_NPM_REGISTRY_URL }}
scan_image: true
secrets:
npm_registry_auth_token: ${{ secrets.NPM_PUBLISH_TOKEN }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
build-223-multi-architecture:
name: Build multi-architecture container image
needs: build-223
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
image_tag_prefix: '2.2.3-'
secrets:
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
upload-223-stage:
name: Upload image to staging ECR
if: github.ref_name == 'main'
needs: build-223-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: stage
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-223-multi-architecture.outputs.image }}
image_tag_prefix: '2.2.3-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}
upload-223-prod:
name: Upload image to production ECR
if: github.ref_name == 'main'
needs: build-223-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: production
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-223-multi-architecture.outputs.image }}
image_tag_prefix: '2.2.3-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}
build-310:
name: Build 3.1.x container images
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
dockerfile_path: Dockerfile-3.1
image_tag_prefix: '3.1.x-'
package_dependencies: |
@flowforge/nr-project-nodes
build_context: 'node-red-container'
npm_registry_url: ${{ vars.PUBLIC_NPM_REGISTRY_URL }}
scan_image: true
secrets:
npm_registry_auth_token: ${{ secrets.NPM_PUBLISH_TOKEN }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
build-310-multi-architecture:
name: Build multi-architecture container image
needs: build-310
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
image_name: 'node-red'
image_tag_prefix: '3.1.x-'
secrets:
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
upload-310-stage:
name: Upload image to staging ECR
if: github.ref_name == 'main'
needs: build-310-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: stage
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-310-multi-architecture.outputs.image }}
image_tag_prefix: '3.1.x-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}
upload-310-prod:
name: Upload image to production ECR
if: github.ref_name == 'main'
needs: build-310-multi-architecture
uses: flowfuse/github-actions-workflows/.github/workflows/[email protected]
with:
environment: production
service_name: 'node-red'
deployment_name: 'node-red'
container_name: 'node-red'
deploy: false
image: ${{ needs.build-310-multi-architecture.outputs.image }}
image_tag_prefix: '3.1.x-'
secrets:
aws_access_key_id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_ACCESS_KEY_SECRET }}
temporary_registry_token: ${{ secrets.GITHUB_TOKEN }}
eks_cluster_name: ${{ secrets.EKS_CLUSTER_NAME }}