-
Notifications
You must be signed in to change notification settings - Fork 0
Adjust Github Actions to use Helm deployment #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 6 commits
af00e43
0827669
91f1d9f
e4f9ff5
c192ec3
d9e298a
d6ca342
9f49122
dc19b57
81f520b
20c8091
55f1434
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| name: 'Deploy Helm chart to Kubernetes' | ||
| description: 'Deploy an application to a Kubernetes cluster using its Helm chart' | ||
|
|
||
| inputs: | ||
| release-name: | ||
| description: 'The name of the Helm release' | ||
| required: true | ||
| chart-path: | ||
| description: 'Path to the Helm chart' | ||
| default: '.' | ||
| values-file: | ||
| description: 'Path to the Helm values file' | ||
| required: true | ||
| image-tag: | ||
| description: 'Tag of the container image' | ||
| default: 'latest' | ||
| timeout: | ||
| description: 'Timeout for the Helm command' | ||
| default: '5m' | ||
| working-directory: | ||
| description: 'The working directory' | ||
| default: '.' | ||
|
|
||
| runs: | ||
| using: "composite" | ||
| steps: | ||
| - name: Deploy Helm Chart | ||
| shell: bash | ||
| working-directory: ${{ inputs.working-directory }} | ||
| run: | | ||
| helm upgrade --wait --install ${{ inputs.release-name }} ${{ inputs.chart-path }} \ | ||
| --values ${{ inputs.values-file }} \ | ||
| --atomic --timeout ${{ inputs.timeout }} \ | ||
| --set image.tag=${{ inputs.image-tag }} |
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When I increace the verison, then I adjust also always in the readme under the section |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -52,6 +52,35 @@ The following inputs can be used as `step.with` keys: | |||||
| | `deployment-name` | required | Kubernetes deployment name | | ||||||
| | `working-directory` | `.` | The working directory | | ||||||
|
|
||||||
| ### Deploy to Kubernetes using Helm | ||||||
|
|
||||||
| Deploy an application to a Kubernetes cluster using its Helm diagram. Requires Kubernetes to be configured first. | ||||||
|
|
||||||
| #### Example | ||||||
|
|
||||||
| ```yaml | ||||||
| - uses: ./.github/actions/helm-deploy | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| with: | ||||||
| release-name: my-app | ||||||
| chart-path: my-chart | ||||||
| image-tag: "1.0.0" | ||||||
| values-file: environments/values-test.yaml | ||||||
| timeout: 5m | ||||||
| working-directory: ./infrastructure | ||||||
| ``` | ||||||
|
|
||||||
| #### Inputs | ||||||
|
|
||||||
| The following inputs can be used as `step.with` keys: | ||||||
|
|
||||||
| | Name | Required/Default | Description | | ||||||
| |---------------------|------------------|------------------------------| | ||||||
| | `release-name` | required | The name of the Helm release | | ||||||
| | `values-file` | required | Path to the Helm values file | | ||||||
| | `working-directory` | `.` | The working directory | | ||||||
| | `chart-path` | `.` | Path to the Helm chart | | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Here you are referencing twice a folder, but one time you call it directory and one time path. Would it make sense to align the names? |
||||||
| | `image-tag` | `latest` | Tag of the container image | | ||||||
| | `timeout` | `5m` | Timeout for the Helm command | | ||||||
|
|
||||||
| ## Versioning | ||||||
|
|
||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you think about renaming
aboutbits/github-actions-kubernetes/deploytoaboutbits/github-actions-kubernetes/kubectl-deploy? We could just simply release everything with version 2 then it should not be a problem and we have it more evident for the future?