Skip to content

CLI Reference

This page provides documentation for our command line tools.

ptah

https://stackoverflow.com/a/71008105

Usage:

ptah [OPTIONS] COMMAND [ARGS]...

Options:

  --version
  --install-completion  Install completion for the current shell.
  --show-completion     Show completion for the current shell, to copy it or
                        customize the installation.
  --help                Show this message and exit.

build

Copy all Kubernetes manifests from the current project into the build_output directory.

Usage:

ptah build [OPTIONS]

Options:

  --help  Show this message and exit.

dashboard

Open the Kubernetes dashboard with a prepared bearer token for authentication.

Usage:

ptah dashboard [OPTIONS]

Options:

  --help  Show this message and exit.

deploy

Build the project, ensure the Kind CLI and cluster exit, sync and apply Helm charts, apply Kubernetes manifests, and set up port-forwarding from the cluster to localhost.

Usage:

ptah deploy [OPTIONS]

Options:

  --build / --no-build      [default: build]
  --forward / --no-forward  [default: forward]
  --sync / --no-sync        [default: no-sync]
  --help                    Show this message and exit.

forward

Forward the Kubernetes API server and all deployment ports to localhost; alternatively kill all active "port forward" sessions.

Usage:

ptah forward [OPTIONS]

Options:

  --kill / --no-kill  [default: no-kill]
  --help              Show this message and exit.

nuke

Forcibly delete the Kind cluster, all related resources, and prune dangling Docker images.

Usage:

ptah nuke [OPTIONS]

Options:

  --docker / --no-docker  [default: docker]
  --kind / --no-kind      [default: kind]
  --help                  Show this message and exit.

project

Echo the current project configuration, including default values, to standard output using the specified format.

Usage:

ptah project [OPTIONS]

Options:

  --output [json|yaml]  [default: yaml]
  --help                Show this message and exit.

ssh

Find the first pod with provided app name; then SSH (kubectl exec) into it.

Usage:

ptah ssh [OPTIONS] APP

Options:

  APP     [required]
  --help  Show this message and exit.

sync

Find all Ptah-managed Docker images containing copy statements like

COPY source /target

and synchronize the contents of the source directory with the target directory in all running pods using that image.

Usage:

ptah sync [OPTIONS]

Options:

  --help  Show this message and exit.