Skip to content

Commit

Permalink
feat: add ci to build agent helm chart
Browse files Browse the repository at this point in the history
  • Loading branch information
alee-x committed Oct 8, 2024
1 parent 45f105d commit 26e72bf
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/charts.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build Helm Chart

on:
pull_request:
# Only consider PRs that change files for this asset, including ci scripts
paths:
- '.github/workflows/charts.yaml'
- 'charts/**'
# Make sure all workflows that are "required checks" for a given
# branch protection rule have the same paths: and branches-ignore:
# filters. Otherwise, you can end up in a deadlock waiting on a
# required check that will never be executed.
push:
# Only release off of release and maintenance branches for this asset
branches:
- 'main'
# Only consider pushes that change files for this asset, including ci scripts
paths:
- '.github/workflows/charts.yaml'
- 'charts/**'

permissions:
contents: write
pull-requests: write
actions: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
# Needed to generate releases safely
cancel-in-progress: ${{ github.event_name == 'pull_request' }}

jobs:
# Job name must be unique across repo to target
# branch protection rules "required checks" properly!
agent-helm-chart:
uses: SwanseaUniversityMedical/workflows/.github/workflows/pr-and-release-chart.yaml@v2.0.3-charts
with:
job-name: agent-helm-chart
registry: ${{ vars.HARBOR_REGISTRY }}
registry-user: ${{ vars.HARBOR_USER }}
registry-project: ${{ vars.HARBOR_PROJECT }}
registry-repo: ${{ vars.HARBOR_REPO }}-agent
release-tag-format: 'Agent-Helm-Chart-${version}'
cosign-public-key: ${{ vars.COSIGN_PUBLIC_KEY }}
chart: charts/agent
test-command: |
helm template $CHART --debug
secrets:
cosign-private-key: ${{ secrets.COSIGN_PRIVATE_KEY }}
cosign-password: ${{ secrets.COSIGN_PASSWORD }}
registry-token: ${{ secrets.HARBOR_TOKEN }}

0 comments on commit 26e72bf

Please sign in to comment.