Install Kubeform kubectl Plugin

Kubeform provides a kubectl plugin to interact with Kubeform resources.

Install using Krew

Kubeform kubectl plugin can be installed using Krew. Krew is the plugin manager for kubectl command-line tool. To install follow the steps below:

  • Install krew following the steps here.

  • If you have already installed krew, please upgrade krew to version v0.4.0 or later so that you can use custom plugin indexes.

kubectl krew upgrade
kubectl krew version
kubectl krew index add appscode
kubectl krew index list
kubectl krew update
  • Install Kubeform kubectl plugin following the commands below:
kubectl krew install appscode/kf
kubectl kf version
  • If Kubeform kubectl plugin is already installed, run the following command to upgrade the plugin:
kubectl krew upgrade
kubectl kf version

Install using pre-built binary

You can download the pre-build binaries from kubeform/cli releases and put it into one of your installation directory denoted by $PATH variable.

Here is a simple Linux command to install the latest 64-bit Linux binary directly into your /usr/local/bin directory:

# Linux amd 64-bit
curl -o kubectl-kf.tar.gz -fsSL \
  && tar zxvf kubectl-kf.tar.gz \
  && chmod +x kubectl-kf-linux-amd64 \
  && sudo mv kubectl-kf-linux-amd64 /usr/local/bin/kubectl-kf \
  && rm kubectl-kf.tar.gz

# Mac OSX 64-bit
curl -o kubectl-kf.tar.gz -fsSL \
  && tar zxvf kubectl-kf.tar.gz \
  && chmod +x kubectl-kf-darwin-amd64 \
  && sudo mv kubectl-kf-darwin-amd64 /usr/local/bin/kubectl-kf \
  && rm kubectl-kf.tar.gz

If you prefer to install kubectl Kubeform cli from source code, make sure that your go development environment has been setup properly. Then, just run:

go get

Please note that this will install Kubeform cli from master branch which might include breaking and/or undocumented changes.