cli

by tektoncd

tektoncd / cli

A CLI for interacting with Tekton!

181 Stars 119 Forks Last release: 29 days ago (v0.13.0) Apache License 2.0 852 Commits 21 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:

Tekton Pipelines cli

Go Report Card

Tekton logo

The Tekton Pipelines cli project provides a CLI for interacting with Tekton!

Getting Started

Installing
tkn

Download the latest binary executable for your operating system:

  • Mac OS X

    • tektoncd-cli
      is available from brew:
  brew install tektoncd-cli
  # Get the tar.xz
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tkn_0.13.0_Darwin_x86_64.tar.gz
  # Extract tkn to your PATH (e.g. /usr/local/bin)
  sudo tar xvzf tkn_0.13.0_Darwin_x86_64.tar.gz -C /usr/local/bin tkn
  choco install tektoncd-cli --confirm
  • Or by the released zip file in the instructions below:

  • Uncompress the zip file

  • Add the location of where the executable is to your

    Path
    by opening
    Control Panel>System and Security>System>Advanced System Settings
  • Click on

    Environment Variables
    , select the
    Path
    variable, and click
    Edit
  • Click

    New
    and add the location of the uncompressed zip to the
    Path
  • Finish by clicking

    Ok

Linux tarballs

  # Get the tar.xz
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tkn_0.13.0_Linux_x86_64.tar.gz
  # Extract tkn to your PATH (e.g. /usr/local/bin)
  sudo tar xvzf tkn_0.13.0_Linux_x86_64.tar.gz -C /usr/local/bin/ tkn
  # Get the tar.xz
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tkn_0.13.0_Linux_arm64.tar.gz
  # Extract tkn to your PATH (e.g. /usr/local/bin)
  sudo tar xvzf tkn_0.13.0_Linux_arm64.tar.gz -C /usr/local/bin/ tkn
  # Get the tar.gz
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tkn_0.13.0_Linux_s390x.tar.gz
  # Extract tkn to your PATH (e.g. /usr/local/bin)
  sudo tar xvzf tkn_0.13.0_Linux_s390x.tar.gz -C /usr/local/bin/ tkn
  # Get the tar.gz
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tkn_0.13.0_Linux_ppc64le.tar.gz
  # Extract tkn to your PATH (e.g. /usr/local/bin)
  sudo tar xvzf tkn_0.13.0_Linux_ppc64le.tar.gz -C /usr/local/bin/ tkn

Linux RPMs

If you are running on any of the following rpm based distros:

  • Fedora30
  • Fedora31
  • Centos7
  • Centos8
  • EPEL
  • RHEL8

you would be able to use @chmouel's unofficial copr package repository by running the following commands:

  dnf copr enable chmouel/tektoncd-cli
  dnf install tektoncd-cli

On any other RPM based distros, you can install the rpm directly:

    rpm -Uvh https://github.com/tektoncd/cli/releases/download/v0.13.0/tektoncd-cli-0.13.0_Linux-64bit.rpm

Linux Debs

If you are running on the latest Ubuntu or Debian, you would be able to use our TektonCD CLI PPA:

  sudo apt update;sudo apt install -y gnupg
  sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3EFE0E0A2F2F60AA
  echo "deb http://ppa.launchpad.net/tektoncd/cli/ubuntu eoan main"|sudo tee /etc/apt/sources.list.d/tektoncd-ubuntu-cli.list
  sudo apt update && sudo apt install -y tektoncd-cli

The PPA may work with older releases, but that hasn't been tested.

On any other Debian or Ubuntu based distro, you can simply install the binary package directly with

dpkg
:
  curl -LO https://github.com/tektoncd/cli/releases/download/v0.13.0/tektoncd-cli-0.13.0_Linux-64bit.deb
  dpkg -i tektoncd-cli-0.13.0_Linux-64bit.deb

Source install

If you have go installed and you want to compile the CLI from source, you can checkout the Git repository and run the following commands:

  export GO111MODULE=on
  make bin/tkn

This will output the

tkn
binary in
bin/tkn

tkn
as a
kubectl
plugin

kubectl
will find any binary named
kubectl-*
on your PATH and consider it as a plugin. After installing tkn, create a link as kubectl-tkn
shell
$ ln -s /usr/local/bin/tkn /usr/local/bin/kubectl-tkn
Run the following to confirm tkn is available as a plugin:
shell
$ kubectl plugin list
You should see the following after running kubectl plugin list if tkn is available as a plugin:
shell
/usr/local/bin/kubectl-tkn
If the output above is shown, run kubectl-tkn to see the list of available tkn commands to run.

Useful Commands

The following commands help you understand and effectively use the Tekton CLI:

For every

tkn
command, you can use
-h
or
--help
flags to display specific help for that command.

Want to contribute

We are so excited to have you!

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.