GoogleContainerTools / GoogleContainerTools/skaffold

port-forward events should indicate user-defined forwards

Open
#7,081 0 comments 0 reactions 0 assignees View on GitHub
area/portforward kind/enhancement priority/p2
Dominant language
Go
Stars
15.9k
Forks
1.7k
Avg merge
3d 9h
Merged PRs (30d)
10

Description

### Expected behavior

Running the `jib-sync` example, which includes a user-defined port-forward, should be visible from within Cloud Code.
```yaml
portForward:
- resourceType: pod
resourceName: test-file-sync
port: 8080
```

### Actual behavior

The forward is not shown:
![Screen Shot 2022-02-04 at 5 11 31 PM](https://user-images.githubusercontent.com/202851/152610123-e6a3298b-4ac8-4499-8ab5-69a48febdda0.png)

The `portEvent` provides no indication that the port-forward was user-defined:
```
{
"result": {
"timestamp": "2022-02-04T21:54:24.624180Z",
"portEvent": {
"id": "",
"task_id": "PortForward-1",
"localPort": 8080,
"podName": "",
"containerName": "",
"namespace": "default",
"portName": "",
"resourceType": "pod",
"resourceName": "test-file-sync",
"address": "127.0.0.1",
"targetPort": {
"type": 0,
"intVal": 8080,
"strVal": ""
}
}
}
}
```

### Information

- Skaffold version: 1.35.1
- Operating system: macOS
- Installed via: Cloud Code

Contributor guide

Open the contributing guide

Research direction

Run the jib-sync example and inspect the portEvent produced for the user-defined port-forward in the shown configuration. Trace how that event is formed and consumed by Cloud Code. Done means the event indicates that the forward is user-defined so Cloud Code can display it.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, kubernetes
Domain
api, devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.