Kubernetes icon

Kubernetes

Interact with Kubernetes

Namespaces → Port Forward

AI-generated

Overview

This node interacts with a Kubernetes cluster to perform various operations on Kubernetes resources. Specifically, the 'Port Forward' operation establishes a port forwarding session to a specified resource within a Kubernetes namespace, allowing local access to the resource's ports. This is useful for accessing services or pods running inside the cluster from outside, such as for debugging or development purposes.

Use Case Examples

  1. Forward a port from a pod in the 'default' namespace to access a web service running inside the cluster locally.
  2. Establish port forwarding to a Kubernetes service to test connectivity without exposing it externally.

Output

JSON

  • json - The result of the port forwarding operation, typically connection details or status.

Dependencies

  • Requires Kubernetes API credentials to authenticate and interact with the cluster.

Troubleshooting

  • Ensure the resource name is provided; otherwise, the node throws an error indicating the resource name is required for the port-forward operation.
  • Verify that the Kubernetes credentials are correctly configured and valid to avoid authentication errors.
  • Check network connectivity to the Kubernetes cluster to prevent connection failures during port forwarding.

Links

Discussion