-
Notifications
You must be signed in to change notification settings - Fork 4
42 lines (39 loc) · 1.09 KB
/
lint-helm.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Helm lint
on:
pull_request:
paths:
- 'kubernetes/**'
- '.tool-versions'
- '.github/actions/**'
- '.github/workflows/lint-helm.yaml'
push:
branches:
- master
paths:
- 'kubernetes/**'
- '.tool-versions'
- '.github/actions/**'
- '.github/workflows/lint-helm.yaml'
jobs:
helm-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- name: Check if kubernetes/*/* is not empty
id: check-kubernetes-directory
run: |
if [ "$(ls -A kubernetes/*/* 2>/dev/null)" ]; then
echo "Kubernetes directory is not empty."
echo "::set-output name=not_empty::true"
else
echo "Kubernetes directory is empty."
echo "::set-output name=not_empty::false"
fi
- name: Lint
run: |
if ${{ steps.check-kubernetes-directory.outputs.not_empty }}; then
helm lint kubernetes/*/*
else
echo "Skipping Helm lint because kubernetes/*/* is empty."
fi