Introduction
Sometimes you want to access an app running inside Kubernetes from your own computer without exposing it publicly. kubectl port-forward lets you connect your local computer to a port inside a Kubernetes pod securely and easily.
When you want to test a web app running inside a pod without changing its service or ingress setup
When you need to connect to a database inside Kubernetes for debugging or data checks
When you want to securely access an internal service without opening firewall ports
When you want to forward traffic from your local machine to a pod port for development
When you want to quickly check logs or metrics exposed on a pod port