Quick Start
Create your first port-forward configuration, start it, and verify the connection.
Quick Start
In this guide, you'll create a port-forward configuration, start it, and verify that traffic flows from your local machine to a Kubernetes service.
Prerequisites
- kftray or kftui installed
- A running Kubernetes cluster accessible via
kubeconfig - At least one service running in the cluster (we'll use a web service on port 80 as an example)
Verify your cluster access first:
kubectl get services -n defaultStep 1 — Create a Configuration
Click the kftray system tray icon to open the main window.
Click the + button (or press Ctrl+N / Cmd+N).
Fill in the configuration form:
| Field | Value |
|---|---|
| Service | my-service |
| Namespace | default |
| Local Port | 8080 |
| Remote Port | 80 |
| Protocol | tcp |
| Alias | web |
Click Save.
Create a JSON configuration file:
[
{
"service": "my-service",
"namespace": "default",
"local_port": 8080,
"remote_port": 80,
"context": "my-cluster",
"workload_type": "service",
"protocol": "tcp",
"alias": "web"
}
]Save it as config.json, then import it in kftui:
Launch kftui.
Press i to open the import dialog.
Navigate to your config.json file and press Enter.
Step 2 — Start the Port Forward
Toggle the switch next to your "web" configuration, or click Start All to enable all forwards.
A green status indicator means the connection is active.
Use arrow keys to highlight the "web" configuration.
Press Space to select it.
Press f to start forwarding.
The status column changes to Running.
Step 3 — Verify the Connection
Test that traffic flows through the forward:
curl http://localhost:8080You should see the response from your Kubernetes service. For database services, connect your client to localhost:LOCAL_PORT as usual.
Step 4 — Test Automatic Reconnection
Restart the target pod to see automatic reconnection in action:
kubectl rollout restart deployment/my-service -n defaultWatch the kftray status — it briefly shows a reconnection attempt, then returns to green/running. No manual intervention needed.