Skip to content

Commit

Permalink
feat: add kubernetes-schema JSON files locally for air-gapped environ…
Browse files Browse the repository at this point in the history
…ments, based on KUBECTL version
  • Loading branch information
hajowieland committed Jul 4, 2023
1 parent 51ec248 commit d2a26ba
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then ARCHITECTURE=amd64; elif [ "$
curl -sLS "https://github.com/yannh/kubeconform/releases/download/v${KUBECONFORM}/kubeconform-linux-${ARCHITECTURE}.tar.gz" | tar -xzO kubeconform > /usr/local/bin/kubeconform && \
chmod +x /usr/local/bin/kubeconform

# kubernetes-json-schema
RUN git clone --depth 1 --branch master --no-checkout https://github.com/yannh/kubernetes-json-schema.git && \
cd kubernetes-json-schema && git sparse-checkout set v${KUBECTL}-standalone-strict && git checkout master && \
mkdir -p /schema && cp -r v${KUBECTL}-standalone-strict /schema/ && cd .. && rm -rf kubernetes-json-schema

WORKDIR /work

CMD ["helm", "version"]

0 comments on commit d2a26ba

Please sign in to comment.