-
Notifications
You must be signed in to change notification settings - Fork 363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Derive nodePort from Listener port when Service is of type NodePort #2220
Comments
when running kind, we encourage use MetalLB to expose servcie. https://gateway.envoyproxy.io/v0.6.0/user/quickstart/#prerequisites |
we've had multiple asks by users who want to be able to pin the Here's what we can't do
What we could do
|
Thanks for the replies! I investigated MetalB, but on kind since LoadBalancers on the docker network are not easily accessible on Mac/Win docker, it didn't seem to provide any advantage vs. using Option 1 ( I'm also a little curious why adding it to gateway/internal/infrastructure/kubernetes/proxy/resource_provider.go Lines 101 to 102 in ae523a8
Perhaps |
I nerver try on windows, but for mac you can try with https://github.com/chipmk/docker-mac-net-connect |
@chromakode the ports are translated from the gateway-api I think 1. is a reasonable way to achieve this |
@tamalsaha @tommie I believe ya'll are running in |
Currently we are using annotations like below on gateway to configure node port for a listener port in our gateway.
|
@tamalsaha so the listener port value is a place holder, being unused, or are you counting on it for something ? |
It is not a placeholder. We set it to the actual value of a listener port used in the gateway. Same way node port is an actual value. Effectively, we are proving a map from svc-port => node-port.
|
if the listener port directly mapped to the nodePort (only for |
What do you mean by that? In our case the listener port becomes the envoy service port. We make the envoy service a NodePort type service using |
then the generated Envoy service would have a spec that looks like
|
I see. Here the svc port and node port are same. I don't know if that will always be a preferred option especially for HTTP/S type workloads. |
In my case, I just want to set up a small k8s from nothing, while being able to scale it seamlessly. For that, MetalLB is way overkill: just start Envoy on a couple of nodes, and have a DNS controller that reads the Envoy services and updates records. Since I don't run a dedicated LB, there's no point in adding yet another indirection, because the traffic has already arrived at my cluster. (Hence my original aversion against requiring MetalLB rather than supporting NodePort natively.)
(I feel I'm missing some context and, uhm, knowledge, to answer. It's been a while since I was playing with Envoy. Got stuck on an unrelated task.) Yes, I think your example makes sense to support using Envoy as the cluster LB, though I don't remember how that differs from now. (IIRC, this part of EG ended up working well for me, but haven't run the test code since summer.) |
Users should be able to now specify an explicit nodePort using #2719, closing this one |
Hi! When running in kind, one of the convenient ways to handle ingress to set up an external port mapping with a static port number.
I haven't found a way to specify
nodePort
for the gateway's service, so it's not possible to set up a port mapping because the number is dynamically assigned. It'd be useful to be able to specify the desirednodePort
in theenvoyService
spec.The text was updated successfully, but these errors were encountered: