Skip to content

Commit 6c4d2b8

Browse files
committed
add helm package building into CI
Signed-off-by: Luiz Oliveira <ziuloliveira@gmail.com>
1 parent c6aceba commit 6c4d2b8

File tree

3 files changed

+17
-4
lines changed

3 files changed

+17
-4
lines changed

.github/workflows/build.yaml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ jobs:
2727
runner: ubuntu-latest
2828
test:
2929
uses: ./.github/workflows/tests.yaml
30-
build:
31-
name: Building
30+
build-docker:
31+
name: Docker Building
3232
runs-on: ubuntu-latest
3333
needs: [versioning, test]
3434
if: github.ref_name == 'main' || github.event_name == 'release'
@@ -60,3 +60,17 @@ jobs:
6060
tags: |
6161
${{ secrets.DOCKER_REGISTRY }}/${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_REPOSITORY }}:${{ needs.versioning.outputs.MajorMinorPatch }}
6262
${{ secrets.DOCKER_REGISTRY }}/${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_REPOSITORY }}:latest
63+
build-helm:
64+
name: Helm Building
65+
runs-on: ubuntu-latest
66+
needs: [versioning, test]
67+
if: github.ref_name == 'main' || github.event_name == 'release'
68+
steps:
69+
- uses: actions/checkout@v4
70+
- name: Helm Build
71+
run: |
72+
helm package ./charts/swagger-operator --app-version ${{ needs.versioning.outputs.MajorMinorPatch }} --version ${{ needs.versioning.outputs.MajorMinorPatch }}
73+
helm repo index . --url ${{ secrets.DOCKER_REGISTRY }}/${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_REPOSITORY }}
74+
helm registry login ${{ secrets.DOCKER_REGISTRY }} --username ${{ secrets.DOCKER_USERNAME }} --password ${{ secrets.DOCKER_PASSWORD }}
75+
helm push swagger-operator-${{ needs.versioning.outputs.MajorMinorPatch }}.tgz oci://${{ secrets.DOCKER_REGISTRY }}/${{ secrets.DOCKER_USERNAME }}
76+

charts/swagger-operator/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ version: 0.1.0
2121
# incremented each time you make changes to the application. Versions are not expected to
2222
# follow Semantic Versioning. They should reflect the version the application is using.
2323
# It is recommended to use it with quotes.
24-
appVersion: "1.16.0"
24+
appVersion: "0.1.1"

charts/swagger-operator/values.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ image:
88
repository: ziuloliveira/swagger-operator
99
pullPolicy: Always
1010
# Overrides the image tag whose default is the chart appVersion.
11-
tag: "latest"
1211

1312
imagePullSecrets: []
1413
nameOverride: ""

0 commit comments

Comments
 (0)