Installation Methods

Methods for installing the Kyverno CLI

Install via Homebrew

The Kyverno CLI can also be installed with Homebrew as a formula.

1brew install kyverno

Install via Krew

You can use Krew to install the Kyverno CLI:

1# Install Kyverno CLI using kubectl krew plugin manager
2kubectl krew install kyverno
3
4# test the Kyverno CLI
5kubectl kyverno version  

Install via AUR (archlinux)

You can install the Kyverno CLI via your favorite AUR helper (e.g. yay)

1yay -S kyverno-git

Install in GitHub Actions

The Kyverno CLI can be installed in GitHub Actions using kyverno-cli-installer from the GitHub Marketplace. Please refer to kyverno-cli-installer for more information.

Manual Binary Installation

The Kyverno CLI may also be installed by manually downloading the compiled binary available on the releases page. An example of installing the Kyverno CLI v1.12.0 on a Linux x86_64 system is shown below.

1curl -LO https://github.com/kyverno/kyverno/releases/download/v1.12.0/kyverno-cli_v1.12.0_linux_x86_64.tar.gz
2tar -xvf kyverno-cli_v1.12.0_linux_x86_64.tar.gz
3sudo cp kyverno /usr/local/bin/

Building the CLI from source

You can also build the CLI binary from the Git repository (requires Go).

1git clone https://github.com/kyverno/kyverno
2cd kyverno
3make build-cli
4sudo mv ./cmd/cli/kubectl-kyverno/kubectl-kyverno /usr/local/bin/

Last modified April 08, 2024 at 8:29 AM PST: Refactor links (#1205) (5060f3d)