portForward to multiple ports

166 views
Skip to first unread message

Alan Szlosek

unread,
Aug 3, 2021, 10:42:53 AM8/3/21
to skaffold-users
Hi Skaffold Team!

We're slowly containerizing our dev environment (ie. developer laptops) and are experimenting with Skaffold, Minikube and Docker for Mac. Given that some services will be running in a container/k8s and others will be running directly on the host we are using Skaffold's portForward support to listen on all interfaces (address=0.0.0.0) instead of the default of localhost (I hope that makes sense). This allows a containerized service to talk to others running on the host via an endpoint like host.minikube.internal. Unfortunately we have a few containers that expose more than one port, so Issue 5763 is blocking us.

Do you have any suggestions for a workaround? What's the best way for me to upvote that issue? :-) 

Brian de Alwis

unread,
Aug 3, 2021, 12:07:42 PM8/3/21
to Alan Szlosek, skaffold-users
Hi Alan.

Good news is that we have a fix for #5732.  I was never able to reproduce #5732 but we had another report that clued me in that it was a problem with forwarding services and user-defined port-forwards.

It would be very helpful if you could try it out and verify that it fixes your issue.  You'll need the Go toolchain installed and then you can run `make` and find the binary in `out/skaffold`.

Brian.

--
You received this message because you are subscribed to the Google Groups "skaffold-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to skaffold-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/skaffold-users/99dfdc76-eaf0-4e67-8678-f5ed02fda3a3n%40googlegroups.com.

Alan Szlosek

unread,
Aug 4, 2021, 1:41:24 PM8/4/21
to skaffold-users
Brian,

Wow, thank you! That did indeed work. I'm now seeing multiple instances of kubectl port-forward on 0.0.0.0 for my service (one for each port).

Good to know a fix is in the works for this issue.

Looks like you'll be able to close out ~3 issues with one PR. Impressive! :-) 
Reply all
Reply to author
Forward
0 new messages