[#63] Add lint to CI #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run CI | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- '*' | |
pull_request: | |
jobs: | |
linter: | |
name: Check Charts Syntax | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Helm | |
uses: azure/[email protected] | |
with: | |
version: v3.14.4 | |
- name: Add dependency chart repos | |
run: | | |
helm repo add bitnami https://charts.bitnami.com/bitnami | |
- name: Run Helm lint | |
run: | | |
for CHART_DIR in ./charts/*; do | |
if [ -d "$CHART_DIR" ]; then | |
# Run helm dependencies build | |
echo "Running 'helm dependencies build' for $(basename "$CHART_DIR")" | |
helm dependencies build "$CHART_DIR" | |
if [ $? -ne 0 ]; then | |
exit 1 | |
fi | |
# Run helm lint | |
helm lint "$CHART_DIR" | |
if [ $? -ne 0 ]; then | |
exit 1 | |
fi | |
fi | |
done |