-
-
Notifications
You must be signed in to change notification settings - Fork 2
205 lines (185 loc) · 6.36 KB
/
ci.yml
File metadata and controls
205 lines (185 loc) · 6.36 KB
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
name: Build And Deploy Lighthouse
on:
push:
branches: [ "main", "features/**" ]
paths:
- "Lighthouse.Backend/**"
- "Lighthouse.Backend.Tests/**"
- "Lighthouse.EndToEndTests/**"
- "Lighthouse.Frontend/**"
- ".github/workflows/ci*.yml"
- ".github/actions/**"
- "examples/postgres/**"
pull_request:
branches: [ "main" ]
workflow_dispatch:
jobs:
version:
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_version.yml
name: Version
permissions:
actions: read
contents: write
changes:
uses: ./.github/workflows/ci_changes.yml
name: Detect Changes
backend:
needs: changes
uses: ./.github/workflows/ci_backend.yml
name: Verify Backend
with:
backend: ${{ needs.changes.outputs.backend }}
secrets: inherit
frontend:
needs: changes
uses: ./.github/workflows/ci_frontend.yml
name: Verify Frontend
with:
frontend: ${{ needs.changes.outputs.frontend }}
secrets: inherit
e2e:
needs: changes
uses: ./.github/workflows/ci_e2e.yml
name: Verify End to End Tests
with:
e2e: ${{ needs.changes.outputs.e2e }}
packageapp:
needs: version
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_packageapp.yml
name: Package App
permissions:
actions: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
version: ${{ needs.version.outputs.version }}
docker:
needs: version
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_docker.yml
name: Build and Push Docker Image
permissions:
packages: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
secrets: inherit
sbom:
needs: version
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_sbom.yml
name: Generate SBOM
permissions:
contents: read
with:
version: ${{ needs.version.outputs.version }}
# Linux verification with EndToEnd tests
verifysqlite:
needs: [frontend, backend, e2e, packageapp, version]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_verifysqlite.yml
name: Verify SQLite Linux Build
permissions:
actions: read
with:
version: ${{ needs.version.outputs.version }}
secrets: inherit
verifypostgres:
needs: [frontend, backend, e2e, packageapp, version]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_verifypostgres.yml
name: Verify Postgres Linux Build
permissions:
actions: read
with:
version: ${{ needs.version.outputs.version }}
secrets: inherit
# Linux standalone (Tauri AppImage)
package-linux-standalone:
needs: [version, packageapp]
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_package-linux-standalone.yml
name: Package Linux Standalone
permissions:
actions: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
version: ${{ needs.version.outputs.version }}
secrets: inherit
# Windows standalone (Tauri NSIS + MSI)
package-win-standalone:
needs: [version, packageapp]
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_package-win-standalone.yml
name: Package Windows Standalone
permissions:
actions: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
version: ${{ needs.version.outputs.version }}
secrets: inherit
# Windows signing and verification
codesign-windows:
needs: [version, package-win-standalone]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_codesign-windows.yml
name: Code Sign Windows App
permissions:
actions: write
secrets: inherit
with:
version: ${{ needs.version.outputs.version }}
verifywindows:
needs: [codesign-windows, version]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_verifywindows.yml
name: Verify Windows App
permissions:
actions: read
with:
version: ${{ needs.version.outputs.version }}
# macOS standalone (Tauri DMG)
package-macos-standalone:
needs: [version, packageapp]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_package-macos-standalone.yml
name: Package macOS Standalone
permissions:
actions: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
version: ${{ needs.version.outputs.version }}
secrets: inherit
verifymacos:
needs: [package-macos-standalone, version]
# Run version even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_verifymacos.yml
name: Verify macOS App
permissions:
actions: read
with:
version: ${{ needs.version.outputs.version }}
secrets: inherit
release:
needs: [version, docker, sbom, verifysqlite, verifypostgres, verifymacos, verifywindows, package-linux-standalone]
# Run even if some prior jobs were skipped, but not if they failed
if: always() && !cancelled() && !contains(needs.*.result, 'failure')
uses: ./.github/workflows/ci_release.yml
name: Release
permissions:
contents: write
packages: write
actions: read
id-token: write
with:
fileversion: ${{ needs.version.outputs.fileversion }}
version: ${{ needs.version.outputs.version }}
secrets: inherit