O que Conftest Structured Configuration Policy Testing with OPA Rego faz?
Conftest is a CLI tool that tests structured configuration data using the Open Policy Agent Rego language. It validates Kubernetes manifests, Terraform configs, Dockerfiles, CI pipelines, and any other structured format against custom policy rules.
Installation
Basic usage or getting-started notes:
-
Here's a quick example. Save the following as policy/deployment.rego:
-
Assuming you have a Kubernetes deployment in deployment.yaml you can run Conftest like so:
-
Extracted from upstream docs: https://raw.githubusercontent.com/open-policy-agent/conftest/HEAD/README.md