-
Notifications
You must be signed in to change notification settings - Fork 0
65 lines (59 loc) · 1.91 KB
/
ci.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
name: ci
on:
workflow_dispatch:
push:
branches-ignore:
- "preview/**"
paths-ignore:
# - .github
# - .scripts
# - .charts
- LICENSE
- README.md
- build.sh
- build.ps1
pull_request:
branches: [main]
types: [opened, synchronize, reopened]
jobs:
versioning:
uses: f2calv/gha-workflows/.github/workflows/gha-release-versioning.yml@v1
with:
tag-prefix: ''
tag-and-release: false
app:
uses: f2calv/gha-workflows/.github/workflows/app-build-rust.yml@v1
needs: versioning
with:
fullSemVer: ${{ needs.versioning.outputs.fullSemVer }}
image:
uses: f2calv/gha-workflows/.github/workflows/container-image-build.yml@v1
permissions:
packages: write #for pushing container image
contents: read #note: for private repos setting packages to write, will reset all other permissions to none (weird?)
needs: [versioning, app]
with:
registry: ghcr.io/${{ github.repository_owner }}
tag: ${{ needs.versioning.outputs.semVer }}
tag-major: ${{ needs.versioning.outputs.major }}
tag-minor: ${{ needs.versioning.outputs.minor }}
chart:
uses: f2calv/gha-workflows/.github/workflows/helm-chart-package.yml@v1
permissions:
packages: write #for pushing helm artifact
contents: read #note: for private repos setting packages to write, will reset all other permissions to none (weird?)
needs: [versioning, app, image]
with:
registry: ghcr.io/${{ github.repository_owner }}
chart-repository-prefix: charts/
tag: ${{ needs.versioning.outputs.semVer }}
release:
needs: [versioning, app, image, chart]
if: github.ref == 'refs/heads/main'
uses: f2calv/gha-workflows/.github/workflows/gha-release-versioning.yml@v1
permissions:
contents: write
with:
semVer: ${{ needs.versioning.outputs.semVer }}
tag-prefix: ''
move-major-tag: false