-
Notifications
You must be signed in to change notification settings - Fork 2k
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
TCP Support? #164
Comments
@hapnermw Why doesn't the config map approach of the nginx-ingress-controller work you? Not sure If completely understand the distinction between static and dynamic deployments in your example. |
The reason k8s added the ingress abstraction is to support the dynamic registration of virtual hosts (virtual servers) for services (via HTTP hostname or TLS SNI). NginX's ingress controller supports this by dynamically discovering k8s ingress resources and configuring HTTP virtual servers for them. NginX has supported TLS/TCP virtual servers for some time. They do TLS/TCP session load balancing and require different configuration. The NginX k8s ingress controller does not support this NginX feature because currently k8s ingress does not support it. This is unfortunate because it wouldn't have been difficult to include syntax for TCP ingress and simply note that support for this was optional. By not including this, k8s has blocked ingress controllers from supporting it. |
@pleshakov I am trying to use the ConfigMap approach but with little success. I am using the following yml (on GKE): apiVersion: v1
kind: ConfigMap
metadata:
namespace: ingress-nginx
name: tcp-services
data:
2000: "lb-test/lb-tcp-headless:2000" This does not seem to have any effect and I am still unable to connect to the server via port 2000. Not sure if I am miss-understanding something here? |
@hapnermw load balancing TCP/UDP is available through https://github.com/kubernetes/ingress-nginx/ Ingress controller |
@julienvincent We found that the configmap approach configures correctly the nginx but you are not able to access that port because the Service for the nginx is not modified. To be able to access the port a new port is needed to be added in the Service to open that port in the LoadBalancer and in the Service ports. I have the question if this reconfiguration of the Neginx Service should be done by hand or it is expected to be done by the ngonx-controller module. |
@totemcaf Yes I came to the same conclusion when I was working on this problem. Either way this is the wrong repository to be discussing this on (my bad for discussing an ingress-nginx issue on this thread) |
This is still needed though, unfortunately the LoadBalancer object is not really useful to anyone that doesnt live in the cloud, and Ingress does offer the best approach to get non HTTP traffic LBed. DBs and any other non HTTP traffic still needs to be able to be routed and Nginx is being used to do that right now in many an enterprise but unfortunately we are unable to do so in Kube :( Shouldnt a simple annotation that lets us add the endpoints to watch be sufficient for at least a starting point for this? |
@ebalsumgo |
The current ingress resource doesn't support TCP services. It's likely to support this later; but, for now there needs to be some lower-level/controller-specific way of doing this.
Is there an undocumented way to provide ingress to TCP services.
If not, is there any ongoing development on a work-around for this. Ideally it would be a controller specific annotation and/or configmap that will allow dynamic deployment of TCP services via an ingress resource.
Currently, the kubernetes nginx-ingress-controller provides a work-around for staticly specifying TCP services; however, this isn't very useful for dynamic deployment of services (which is the whole purpose of the ingress facility).
The text was updated successfully, but these errors were encountered: