Skip to content

Commit

Permalink
Setup chart lint and tests using Github Action
Browse files Browse the repository at this point in the history
  • Loading branch information
GaneshSPatil committed Sep 14, 2020
1 parent d851b29 commit 64f1e21
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .github/ct.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
chart-dirs: .
charts:
- gocd
helm-extra-args: --timeout 1200s
check-version-increment: true
debug: true
31 changes: 31 additions & 0 deletions .github/workflows/lint-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Lint and Test Charts

on: [push, pull_request]

jobs:
lint-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Fetch history
run: git fetch --prune --unshallow

- name: Run chart-testing (lint)
id: lint
uses: helm/chart-testing-action@v1.0.0
with:
command: lint
config: .github/ct.yaml

- name: Create kind cluster
uses: helm/kind-action@v1.0.0
# Only build a kind cluster if there are chart changes to test.
if: steps.lint.outputs.changed == 'true'

- name: Run chart-testing (install)
uses: helm/chart-testing-action@v1.0.0
with:
command: install
config: .github/ct.yaml

0 comments on commit 64f1e21

Please sign in to comment.