# Install conftest with Homebrew, Nix, zypper, scoop

Test your configuration files using Open Policy Agent. Version 0.68.2 via Homebrew; verified from local package data. Also installable with nix: nix profile install nixpkgs#conftest.

## Install

```sh
sudo av install brew:conftest
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install conftest
```

  Evidence: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#conftest
```

  Evidence: nixpkgs package indexes: pkgs/by-name/co/conftest/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- zypper (92%):

```sh
sudo zypper install conftest
```

  Evidence: openSUSE Tumbleweed package metadata: conftest from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst

### Windows

- Scoop (92%):

```sh
scoop install main/conftest
```

  Evidence: Scoop official bucket manifest trees: bucket/conftest.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:conftest
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/conftest>
- **Version:** 0.68.2
- **Source summary:** Test your configuration files using Open Policy Agent
- **Homepage:** <https://www.conftest.dev/>
- **Repository:** <https://github.com/open-policy-agent/conftest>
- **Upstream docs:** <https://www.conftest.dev/>
- **License:** Apache-2.0
- **Source archive:** <https://github.com/open-policy-agent/conftest/archive/refs/tags/v0.68.2.tar.gz>
- **Generated:** 2026-07-26T07:20:29+00:00

## Executables

- conftest (cli)
- conftest (alias)

## Build dependencies

- go

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-26
- Package-manager version: 0.68.2
- Local data: ok
- Upstream repository: https://github.com/open-policy-agent/conftest
- Upstream latest detected: v0.68.2 (current)
- info: No package-manager update timestamp was available.
## Project history and usage

Conftest is an Open Policy Agent project for testing structured configuration data with Rego policies. It is commonly used to check Kubernetes manifests, Terraform, Tekton, Serverless configuration, and other machine-readable config before deployment.

### Project history

The README and documentation describe Conftest as a utility for writing tests against structured configuration data and explicitly ground its policy language in Open Policy Agent's Rego. The project lives under the open-policy-agent GitHub organization and documents discussion in the OPA Slack #opa-conftest channel.

The documentation evolved from Kubernetes examples into a broader parser and policy-testing tool. It supports many formats including CUE, Dockerfile, HCL/HCL2, INI, JSON, Jsonnet, nginx, TOML, XML, YAML, CycloneDX, SPDX, and others, making it useful for policy-as-code checks across infrastructure repositories.

### Adoption history

Conftest's adoption tracks the rise of policy-as-code in infrastructure delivery: it lets teams test configs locally, in CI, and through pre-commit before tools such as Kubernetes, Terraform, or deployment platforms consume them. Package-manager availability in Homebrew, Nix, Scoop, and zypper reflects that it is treated as a portable developer and CI binary.

### How it is used

Typical usage is to place Rego files under a policy directory and run conftest test against one or more config files. The tool evaluates deny, violation, and warn rules in the main namespace by default, but supports namespace flags, stdin, metadata, unit tests with conftest verify, and parser builtins for policy tests.

### Why package nerds care

For package curators, Conftest is notable because it packages OPA's policy engine into a focused CLI for files rather than services. It turns Rego from a runtime authorization language into a general-purpose config linting and testing binary that can sit cleanly in CI images and developer package sets.

### Timeline

- 2025: release notes show ongoing OPA dependency updates and parser maintenance in the v0.62 line.
- 2026: v0.68.0 added an nginx parser and moved to OPA 1.15.1.
- 2026: v0.68.1 adjusted push behavior to use Rego v1 by default.
- 2026: v0.68.2 updated the embedded OPA dependency to 1.15.2.

### Related projects

- Official sources tie Conftest to Open Policy Agent, Rego, Kubernetes, Tekton, Terraform, Serverless, Dockerfile, HCL, Jsonnet, CUE, and pre-commit-style workflows.

### Sources

- <https://github.com/open-policy-agent/conftest#readme>
- <https://www.conftest.dev/>
- <https://www.conftest.dev/install/>
- <https://github.com/open-policy-agent/conftest/releases>
- <https://github.com/open-policy-agent/conftest/releases/tag/v0.68.0>
- <https://github.com/open-policy-agent/conftest/releases/tag/v0.68.1>
- <https://github.com/open-policy-agent/conftest/releases/tag/v0.68.2>


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ./conftest.toml
## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** conftest
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

## Other Package-Manager Records

- Nix - conftest: normalized package name match | nixpkgs package indexes: pkgs/by-name/co/conftest/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- zypper - conftest - 0.68.2-1.1: normalized package name match | openSUSE Tumbleweed package metadata: conftest from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Tool to write tests against structured configuration data | https://github.com/open-policy-agent/conftest
- zypper - conftest-bash-completion - 0.68.2-1.1: normalized package name match | openSUSE Tumbleweed package metadata: conftest-bash-completion from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Bash Completion for conftest | https://github.com/open-policy-agent/conftest
- zypper - conftest-fish-completion - 0.68.2-1.1: normalized package name match | openSUSE Tumbleweed package metadata: conftest-fish-completion from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Fish Completion for conftest | https://github.com/open-policy-agent/conftest
- zypper - conftest-zsh-completion - 0.68.2-1.1: normalized package name match | openSUSE Tumbleweed package metadata: conftest-zsh-completion from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Zsh Completion for conftest | https://github.com/open-policy-agent/conftest
- Scoop - main/conftest: normalized package name match | Scoop official bucket manifest trees: bucket/conftest.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1


## Related links

- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [go](https://www.automicvault.com/pkg/brew/go/) - Build dependency declared by Homebrew.
- [allure](https://www.automicvault.com/pkg/brew/allure/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [atf](https://www.automicvault.com/pkg/brew/atf/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [bash_unit](https://www.automicvault.com/pkg/brew/bash-unit/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [bashunit](https://www.automicvault.com/pkg/brew/bashunit/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [bats-core](https://www.automicvault.com/pkg/brew/bats-core/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [beakerlib](https://www.automicvault.com/pkg/brew/beakerlib/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [busted](https://www.automicvault.com/pkg/brew/busted/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [byteman](https://www.automicvault.com/pkg/brew/byteman/) - Shares av.db curated category or tags: cli, developer-tools, testing.
- [pa11y-ci](https://www.automicvault.com/pkg/npm/pa11y-ci/) - Local metadata places this package in an adjacent workflow. Shared terms: cli, developer, developer-tools, open, test.
- [vscode-extension-tester](https://www.automicvault.com/pkg/npm/vscode-extension-tester/) - Local metadata places this package in an adjacent workflow. Shared terms: cli, code, developer, developer-tools, test.
- [counterfeiter](https://www.automicvault.com/pkg/brew/counterfeiter/) - Local metadata places this package in an adjacent workflow. Shared terms: cli, code, developer, developer-tools, test.

## Combined YAML source

View the package source record on GitHub. [combined/conftest.yml](https://github.com/automic-vault/db/blob/main/combined/conftest.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
