Skip to content

Commit 75f16c2

Browse files
committed
support for helm and kustomize
1 parent b863985 commit 75f16c2

File tree

2 files changed

+20
-2
lines changed

2 files changed

+20
-2
lines changed

Dockerfile

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,20 @@ RUN curl -LO "https://github.com/instrumenta/kubeval/releases/latest/download/ku
1111
rm kubeval-linux-amd64.tar.gz && \
1212
mv kubeval /usr/local/bin/
1313

14+
RUN apk add --no-cache ca-certificates
15+
16+
RUN curl -LO "https://get.helm.sh/helm-v3.7.0-linux-amd64.tar.gz" && \
17+
tar xf helm-v3.7.0-linux-amd64.tar.gz && \
18+
rm helm-v3.7.0-linux-amd64.tar.gz && \
19+
mv linux-amd64/helm /usr/local/bin/
20+
21+
RUN apk add --no-cache git
22+
23+
RUN curl -LO "https://github.com/kubernetes-sigs/kustomize/releases/latest/download/kustomize_linux_amd64" && \
24+
chmod +x kustomize_linux_amd64 && \
25+
mv kustomize_linux_amd64 /usr/local/bin/kustomize
26+
1427
COPY entrypoint.sh /entrypoint.sh
1528
RUN chmod +x /entrypoint.sh
1629

17-
ENTRYPOINT ["/entrypoint.sh"]
18-
30+
ENTRYPOINT ["/entrypoint.sh"]

entrypoint.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,9 @@ directory=$INPUT_DIRECTORY
77

88
# Validate Kubernetes manifest files
99
kubeval --strict $directory/*.yaml
10+
11+
# Validate Helm charts
12+
helm lint $directory/charts
13+
14+
# Validate Kustomize overlays
15+
kustomize build $directory/kustomize

0 commit comments

Comments
 (0)