[[command]]
name = "porter"
description = "Porter's PaaS CLI for deploying applications onto Porter-managed Kubernetes clusters. Authenticates against the Porter API via browser-based OAuth (`porter auth login`) or a long-lived API token (`PORTER_TOKEN` env var or `--token`); credentials and the active project/cluster pointer are persisted to `~/.porter/config.json`. Read-only operations issue HTTPS API queries that fetch project, cluster, target, and application metadata, list environment groups and their variable names (no values are printed without an explicit `pull`/`--show-token`), tail container logs, and dump the resolved porter.yaml for an app. Mutating operations include `porter apply` (build a container image and roll out a new revision from porter.yaml), `porter app build/push/create/update/update-tag/rollback` (image build, registry push, app creation, config edits, tag swap, revision revert), `porter app run` (provision a temporary replica in the remote cluster and execute a one-off command inside the application's environment — flags include `--cpu`, `--ram`, `--job`, `--allow-concurrent`, and a paired `porter app run cleanup` that deletes the leftover replicas; this is remote one-off process semantics, not a local env-loading wrapper), `porter env create/set/unset/pull` (write env-group variables and secrets, with `pull` exfiltrating remote secret values to a local .env file), `porter datastore connect` (open a localhost-bound TCP tunnel proxying to a Porter-managed database, intended for use with psql/redis-cli/mongosh against live data), and `porter config set-project`/`set-cluster` (rewrite the local active-context pointer in `~/.porter/config.json`). Written in Go at github.com/porter-dev/porter; minor releases land roughly weekly with frequent flag-surface churn on the app and apply commands."
url = "https://docs.porter.run/standard/cli"
researched_version = "github.com/porter-dev/porter @ master, 2026-05-08"
bare_flags = ["--help", "--version", "-h", "-v"]

[[command.sub]]
name = "app"
[[command.sub.sub]]
name = "list"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "manifests"
bare = false
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "yaml"
bare = false
standalone = ["--helm-overrides", "--help", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "build"
candidate = true
[[command.sub.sub]]
name = "create"
candidate = true
[[command.sub.sub]]
name = "exec"
candidate = true
[[command.sub.sub]]
name = "logs"
candidate = true
[[command.sub.sub]]
name = "push"
candidate = true
[[command.sub.sub]]
name = "rollback"
candidate = true
[[command.sub.sub]]
name = "run"
candidate = true
[[command.sub.sub]]
name = "update"
candidate = true
[[command.sub.sub]]
name = "update-tag"
candidate = true

[[command.sub]]
name = "auth"
[[command.sub.sub]]
name = "login"
level = "SafeWrite"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project", "--token"]
[[command.sub.sub]]
name = "logout"
level = "SafeWrite"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]

[[command.sub]]
name = "cluster"
[[command.sub.sub]]
name = "list"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]

[[command.sub]]
name = "config"
nested_bare = true
standalone = ["--help", "--show-token", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "set-project"
level = "SafeWrite"
max_positional = 1
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "set-cluster"
level = "SafeWrite"
max_positional = 1
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]

[[command.sub]]
name = "env"
[[command.sub.sub]]
name = "list"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]
[[command.sub.sub]]
name = "create"
candidate = true
[[command.sub.sub]]
name = "pull"
candidate = true
[[command.sub.sub]]
name = "set"
candidate = true
[[command.sub.sub]]
name = "unset"
candidate = true

[[command.sub]]
name = "project"
[[command.sub.sub]]
name = "list"
standalone = ["--help", "-h"]
valued = ["--cluster", "--project"]

[[command.sub]]
name = "target"
[[command.sub.sub]]
name = "list"
standalone = ["--help", "--preview", "-h"]
valued = ["--cluster", "--project"]

[[command.sub]]
name = "apply"
candidate = true
[[command.sub]]
name = "datastore"
candidate = true
[[command.sub]]
name = "deploy"
candidate = true
[[command.sub]]
name = "exec"
candidate = true
[[command.sub]]
name = "logs"
candidate = true
[[command.sub]]
name = "port-forward"
candidate = true
[[command.sub]]
name = "run"
candidate = true
[[command.sub]]
name = "update"
candidate = true
