$ ./guess_the_languageDevOps
DevOps · easy · #207

What does this command do?

kubectl port-forward pod/web 8080:80
  1. Exposes the pod publicly on port 8080
  2. Tunnels local port 8080 to pod port 80
  3. Changes the pod's container port to 8080
  4. Creates a Service that maps 8080 to 80
It opens a temporary tunnel from your machine to the pod, handy for debugging without exposing anything.
Play DevOps ▸