For complete usage examples and golden path recommendations, see the Platform Examples repository.
jobs:
helm-deploy:
name: Helm Deploy
uses: entur/gha-helm/.github/workflows/deploy.yml@v1
with:
environment: dev
image: amazing-app:latest
slack_channel_id: GXYZABCD # optional slack channel ID for notifications
secrets: inherit # optional - required for slack notifications| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION |
|---|---|---|---|---|
| chart | string | false | "repo_name" |
The chart, defaults to helm/$repository_name |
| cloud_provider | string | false | "gcp" |
Which cloud service provider to use - Google Cloud: 'gcp' or Azure: 'az' |
| container_name | string | false | Replace the image of a named container in the common.containers array. Resolves the array index automatically using the container name in values.yaml. Can be combined with an explicit image_set_path for multi-app deploys. |
|
| environment | string | true | GitHub environment to use Google Cloud: (dev, tst, prd) or Azure: (az-dev, az-test, az-prod) |
|
| gcp_cluster_location | string | false | "europe-west1" |
Defaults to europe-west1 |
| gcp_cluster_name | string | false | Do not use this input | |
| gcp_project_id | string | false | Do not use this input | |
| git_ref | string | false | Git reference to check out before deployment. This can be used as an override if necessary |
|
| image | string | true | The image to deploy, on the form app:tag. Use na value to skip replacing the image version in the helm config. |
|
| image_set_path | string | false | "common.container.image" |
Comma-separated Helm values path(s) for the container image. Override when using aliased common chart dependencies (multi-app deploy), e.g. 'multi-1.container.image,multi-2.container.image' - or when using 3rd party charts. When container_name is set, the default value is skipped; provide a non-default path here to run both mechanisms. |
| namespace | string | false | "repo_name" |
The namespace to use, defaults to repository name |
| release_name | string | false | "repo_name" |
The release name, defaults to repository name |
| slack_channel_id | string | false | Optional Slack channel ID (not name) to post deploy status notifications to. Requires 'secrets: inherit' on the caller workflow and run a '/invite @GitHub Actions' in the Slack channel. |
|
| timeout_minutes | number | false | 30 |
Job timeout in minutes. Helm deploy timeout is half of this value to enable rollback. Default is 30 minutes. |
| values | string | false | "values" |
The values file in ./helm/$app/env/, default values-kub-ent-$environment.yaml |
| OUTPUT | VALUE | DESCRIPTION |
|---|---|---|
| HELM_DEPLOY_STATUS | "${{ jobs.helm-deploy.outputs.HELM_DEPLOY_STATUS }}" |
Helm Deploy Status 0: Success, 1: Failed, 2: Rollback, 3: Rollback Failed |