/kubectl-port_forward_run

`kubectl port-forward-run` is a plugin to help execute a command with a port-forward established.

Primary LanguageGoApache License 2.0Apache-2.0

kubectl port-forward-run

kubectl port-forward-run is a plugin to help execute a command with a port-forward established.

Install

go install github.com/howardjohn/kubectl-port_forward_run@latest

Usage

Example output:

$ kubectl port-forward-run pod/some-pod 80 -- curl localhost:{}

This will port-forward to some-pod on port 80 and execute the curl command. The {} will be replaced with the automatically assigned local port.