From eabd98904e0b4b7c2439f68bcadbf7d17909f64a Mon Sep 17 00:00:00 2001 From: Yannick Evers Date: Thu, 17 Oct 2024 11:10:58 +0000 Subject: [PATCH] Add Workflows --- .../helm-chart-release-on-push-status.yaml | 21 +++++++++++ .../workflows/helm-chart-release-on-tag.yaml | 37 +++++++++++++++++++ status/Chart.yaml | 5 +-- 3 files changed, 59 insertions(+), 4 deletions(-) create mode 100644 .github/workflows/helm-chart-release-on-push-status.yaml create mode 100644 .github/workflows/helm-chart-release-on-tag.yaml diff --git a/.github/workflows/helm-chart-release-on-push-status.yaml b/.github/workflows/helm-chart-release-on-push-status.yaml new file mode 100644 index 0000000..c5ed8c6 --- /dev/null +++ b/.github/workflows/helm-chart-release-on-push-status.yaml @@ -0,0 +1,21 @@ +name: Release Status Chart on branch +on: + push: + branches-ignore: + - 'main' + paths: + - 'status/**' + +concurrency: + group: status-chart + cancel-in-progress: true + +jobs: + release_helm: + uses: dBildungsplattform/dbp-github-workflows/.github/workflows/chart-release.yaml@7 + secrets: inherit + with: + chart_path: "." + chart_name: status + helm_chart_version_generation: ticket_from_branch_timestamp + image_tag_generation: chart_yaml \ No newline at end of file diff --git a/.github/workflows/helm-chart-release-on-tag.yaml b/.github/workflows/helm-chart-release-on-tag.yaml new file mode 100644 index 0000000..5a45f7c --- /dev/null +++ b/.github/workflows/helm-chart-release-on-tag.yaml @@ -0,0 +1,37 @@ +name: Release Charts on Tag +on: + push: + tags: + - '.+-[0-9]+.[0-9]+.[0-9]+' + +concurrency: + group: chart-release + +jobs: + get_tag: + runs-on: ubuntu-latest + outputs: + chart: ${{ steps.nameTag.outputs.chart }} + version: ${{ steps.nameTag.outputs.version }} + steps: + - name: Filter Tag name + uses: olegtarasov/get-tag@v2.1 + id: nameTag + with: + tagRegex: "(?.+?)-(?[0-9]+.[0-9]+.[0-9]+)" + + scan: + uses: dBildungsplattform/dbp-github-workflows/.github/workflows/check-helm-kics.yaml@7 + permissions: + contents: read + release_helm: + needs: scan + uses: dBildungsplattform/dbp-github-workflows/.github/workflows/chart-release.yaml@7 + secrets: inherit + needs: get_tag + with: + chart_path: "." + chart_name: ${{ needs.get_tag.outputs.chart }} + helm_chart_version_generation: specified + helm_chart_version: ${{ needs.get_tag.outputs.version }} + image_tag_generation: chart_yaml \ No newline at end of file diff --git a/status/Chart.yaml b/status/Chart.yaml index 499b549..4f68b66 100644 --- a/status/Chart.yaml +++ b/status/Chart.yaml @@ -12,10 +12,7 @@ description: A Helm chart for Kubernetes # pipeline. Library charts do not define any templates and therefore cannot be deployed. type: application -# This is the chart version. This version number should be incremented each time you make changes -# to the chart and its templates, including the app version. -# Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.3.2 +version: # Managed by Tagging # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to