Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/protosam/kubernetes-manifest-validator
https://github.com/protosam/kubernetes-manifest-validator
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/protosam/kubernetes-manifest-validator
- Owner: protosam
- Created: 2022-11-29T03:49:36.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2022-12-07T01:42:16.000Z (about 2 years ago)
- Last Synced: 2024-07-02T02:06:13.972Z (8 months ago)
- Language: Shell
- Size: 7.81 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Manifest Validator
A container and GitHub action to validate Kubernetes Manifests.## Validating Manifests Locally
Simply run the provided container like this to do local validation. SSH keys are only necessary if fetching additional repos is necessary to validate helm charts.
```
docker run --rm -it \
-v "${PWD}:/workdir" -w /workdir \
-v "${HOME}/.ssh:/home/runner/.ssh" \
ghcr.io/protosam/kubernetes-manifest-validator:latest PATH_TO_VALIDATE [PRE_FETCHED_HELM_CHARTS_PATH]
```## Usage
```yaml
name: Deployment Validation
on: push
jobs:
test:
name: Verify Values
runs-on: ubuntu-latest
steps:
# fetch local repository
- name: Checkout owner/repo
uses: actions/checkout@v3
with:
fetch-depth: 0# fetch repository containing charts for HelmReleases requiring git
- name: Checkout owner/repo for HelmRelease /
uses: actions/checkout@v3
with:
ssh-key: ${{ secrets.SSH_KEY }}
path: "chart_repos//"
fetch-depth: 0
repository: "/"
- name: Validate manifests
uses: protosam/kubernetes-manifest-validator@master
with:
# directory in repo to validate manifests from
path: "."
# directory containing pre-fetched charts from git repositories
chartReposPath: "chart_repos"
```## Building Locally
```
docker build -t ghcr.io/protosam/kubernetes-manifest-validator:latest .
```