Skip to content
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

Nginx should bind to tcp6 as well as tcp4 #96

Closed
sajal opened this issue Dec 7, 2016 · 13 comments
Closed

Nginx should bind to tcp6 as well as tcp4 #96

sajal opened this issue Dec 7, 2016 · 13 comments
Labels
enhancement Pull requests for new features/feature enhancements stale Pull requests/issues with no activity

Comments

@sajal
Copy link

sajal commented Dec 7, 2016

I would be interested in having nginx listen to ipv6. I am using this with hostNetwork: true so I am not limited by lack of IPv6 support in kubernetes.

@thetechnick commented that they have "pull requests incoming for ipv6 binding", I would like to inquire of the status of that.

I think a good default is to listen on IPv6 by default. For PoC I turned on IPv6 by editing the template.

listen 80{{if $server.ProxyProtocol}} proxy_protocol{{end}};<br/>listen [::]:80{{if $server.ProxyProtocol}} proxy_protocol{{end}};<br/>

Is that the correct way to make nginx listen on both v4 and v6?

Aha! Link: https://nginx.aha.io/features/IC-112

@pleshakov
Copy link
Contributor

@sajal
that's the correct way

@thetechnick
Copy link
Contributor

thetechnick commented Dec 8, 2016

@sajal

@thetechnick commented that they have "pull requests incoming for ipv6 binding", I would like to inquire of the status of that.

I am currently working on #77, which will change all variable names in the ingress template from $server to .Server. Because of that I want to postpone the pull request for ipv6 until this is merged, so we do not have to fix the otherwise occuring merge conflicts.

Edit:
The title of this issue is, that ipv6 binding should be the default.
@pleshakov whats your opinion on this matter?

@isaachawley isaachawley added the enhancement Pull requests for new features/feature enhancements label Jul 26, 2018
@kaja-mohideen
Copy link

Any idea when this will be implemented?

I'm trying to use nginx for supporting both IPv4/Ipv6 to front a All-IPv4 K8S cluster.

Ref: https://serverfault.com/questions/969097/nginx-ingress-to-support-ipv4-and-ipv6-for-kubernetes-ipv4-cluster

@pleshakov
Copy link
Contributor

@sajal we're not planning to support it yet.

as a workaround, you can customize the listen directives in the templates as shown in #96 (comment) Please also see https://github.com/nginxinc/kubernetes-ingress/tree/master/examples/custom-templates You also need to configure hostNetwork: true in the IC pod templates. In this case, it is assumed that the clients will use public IPs of the nodes where the IC is running to connect to the Ingress Controller.

@github-actions
Copy link

github-actions bot commented Mar 9, 2021

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the stale Pull requests/issues with no activity label Mar 9, 2021
@ogarrett ogarrett removed the stale Pull requests/issues with no activity label Mar 11, 2021
@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the stale Pull requests/issues with no activity label May 11, 2021
@pleshakov pleshakov removed the stale Pull requests/issues with no activity label May 11, 2021
@unixfox
Copy link

unixfox commented Jul 3, 2021

Hello,

Why can't we just add this into the default template:

listen [::]80 {{if .ProxyProtocol}} proxy_protocol{{end}};
listen [::]443 ssl {{if .HTTP2}} http2{{end}}{{if .ProxyProtocol}} proxy_protocol{{end}};

?

It seems like a very easy fix and the community NGINX ingress is already supporting IPv6, so why is the NGINX ingress from NGINX inc lagging behind?

Would the members of the NGINX Inc accept my pull request if I add similar lines to the default template that would allow IPv6 support?

@Frankkkkk
Copy link

Related to #991

@github-actions
Copy link

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 10 days.

@github-actions github-actions bot added the stale Pull requests/issues with no activity label Dec 21, 2021
@Frankkkkk
Copy link

/unstale

@brianehlert brianehlert removed the stale Pull requests/issues with no activity label Dec 21, 2021
@brianehlert brianehlert changed the title Nginx should bind to tcp6 by default Nginx should bind to tcp6 as well as tcp4 Jan 19, 2022
@github-actions
Copy link

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 10 days.

@github-actions github-actions bot added the stale Pull requests/issues with no activity label Apr 20, 2022
@Frankkkkk
Copy link

Frankkkkk commented Apr 20, 2022

Unless I'm mistaken, this has been fixed in #2576 ? 🎉 Ping @jjngx

@brianehlert
Copy link
Collaborator

It is. There were multiple ipv6 related issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Pull requests for new features/feature enhancements stale Pull requests/issues with no activity
Projects
None yet
Development

No branches or pull requests

9 participants