kx port-forward
Forwards a local port to an indexed resource. Given a workload rather than a Pod, kubectl picks which of its pods to forward to — the same choice kx exec leaves to kubectl.
Unrecognized flags are passed through to kubectl.
Usage
kx port-forward [OPTIONS] <index> <port> [kubectl flags]Arguments
| Argument | Description |
|---|---|
<index> | Row number from the current listing; run kx state to see it |
<port> | Port mapping, local:remote — e.g. 8080:80, or :80 to pick a local port |
Global options
| Option | Description |
|---|---|
--no-color | Disable styled output |
-h, --help | Show this message and exit |
Examples
kx port-forward 1 8080:80