Skip to content

Commit

Permalink
[CMP-1298] Add helm linting (#5)
Browse files Browse the repository at this point in the history
* 🎉 feat(.github/workflows/helm-lint.yml): add GitHub action for Helm linting on pull requests
A new GitHub action has been added to perform Helm linting whenever a pull request is made. This ensures that any changes made to the Helm charts are valid and follow the correct syntax before they are merged into the main branch. This will help maintain the quality of the code and prevent potential issues that could arise from invalid Helm charts.

* 🔧 chore(github-actions): add new ActionLint workflow and update Helm Lint workflow
The new ActionLint workflow is added to ensure that all GitHub Actions workflows are correctly formatted and follow best practices. This will help to catch any potential issues before they are merged into the main branch. The Helm Lint workflow is updated to use the latest version of the checkout action (v4) and to include the GitHub token in the setup step. This will ensure that the workflow has the necessary permissions to perform its tasks.
  • Loading branch information
EwiththeBowtie authored Dec 29, 2023
1 parent 177798f commit 0780564
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/actionlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: ActionLint
on:
push:
branches:
- main
pull_request:

jobs:
actionlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4.1.0

- name: Download actionlint
id: get_actionlint
run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
shell: bash

- name: Check workflow files
shell: bash
run: >
${{ steps.get_actionlint.outputs.executable }}
-color
-ignore "SC2086"
-ignore "SC2155"
-ignore "SC2002"
-ignore "SC2129"
-ignore "SC2046"
-ignore "SC2016"
-ignore "SC2034"
-ignore "SC2005"
21 changes: 21 additions & 0 deletions .github/workflows/helm-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Helm Lint

on:
pull_request:

jobs:
lint-chart:
name: Lint Helm Chart
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Helm
uses: azure/setup-helm@v3.5
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Run Helm Lint
run: helm lint .

0 comments on commit 0780564

Please sign in to comment.