Kubernetes icon

Kubernetes

Interact with Kubernetes

Deployments → Port Forward

AI-generated

Overview

This node interacts with Kubernetes clusters, specifically performing a port forwarding operation on a Kubernetes Deployment resource. It establishes a port forward connection to a specified deployment within a namespace, allowing access to the deployment's ports from the local machine or network. This is useful for debugging, accessing services running inside the cluster, or securely connecting to internal applications without exposing them externally.

Use Case Examples

  1. Forward a port from a Kubernetes deployment to the local machine to access an internal web service for testing.
  2. Use port forwarding to connect to a database running inside a Kubernetes deployment without exposing the database externally.

Output

JSON

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

Dependencies

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

Troubleshooting

  • Ensure Kubernetes credentials are correctly configured and have sufficient permissions to perform port forwarding.
  • Verify that the specified deployment name and namespace are correct and exist in the cluster.
  • Common error: 'Resource name is required for port-forward operation!' indicates the deployment name was not provided; ensure the resourceName parameter is set.
  • Network issues or firewall rules may block the port forwarding connection; verify network accessibility.

Discussion