-
Notifications
You must be signed in to change notification settings - Fork 8.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
Same Path, multiple ports #11334
Comments
This issue is currently awaiting triage. If Ingress contributors determines this is a relevant issue, they will accept it by applying the The Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
You have not provided the information asked in the template of a new bug report. Click the new bug report button and look at the questions asked. Then don't create a new issue but edit this issue description and anwer the questions asked in md format. Once satisfied, then re-open the issue Generally you will need to create 2 ingresses with different hostnames. One terminated with TLS and the other no tls section. if you mean to use HTTPS to the backend pod itself then, this controller has a backend-protocol annotation but I don't think you are using this controller. Also ssl-passthrough does not combine with port 80 obviously /close /close |
@longwuyuan: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
We need to separate HTTP and HTTPS traffic and send them into tenant clusters. Currently traffic was sending only on HTTPS port, this PR enables HTTP traffic forwarding. Nginx ingress does not support setting correct upstream according to type of traffic (http or https) There are set of issues in upstream. - kubernetes/ingress-nginx#1655 - kubernetes/ingress-nginx#9061 - kubernetes/ingress-nginx#11334 Good to know that we found reliable workaround fixes: #209 (comment)
Hey there, I was solving this problem for Cozystack, as we were needed to redirect traffic from infra-ingress-controller to user clusters. So, this rule works with no troubles: apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
annotations:
nginx.ingress.kubernetes.io/backend-protocol: AUTO_HTTP
nginx.ingress.kubernetes.io/configuration-snippet: |
if ($scheme = http) {
set $proxy_upstream_name "mynamespace-myservice-80";
set $proxy_host $proxy_upstream_name;
set $service_port 80;
}
nginx.ingress.kubernetes.io/ssl-passthrough: "true"
nginx.ingress.kubernetes.io/ssl-redirect: "false"
labels:
app.kubernetes.io/managed-by: Helm
name: myservice
namespace: mynamespace
spec:
ingressClassName: mynamespace
rules:
- host: example.org
http:
paths:
- backend:
service:
name: myservice
port:
number: 443
path: /
pathType: ImplementationSpecific
- backend:
service:
name: myservice
port:
number: 80
path: /
pathType: ImplementationSpecific |
|
I need my API hosted in AKS to respond in ports 80 and 443. In port 80 because some of my current clients are using port 80 "hardcoded" and their HttpClients do not follow redirects...
my first try was:
Although AKS accepts this yaml, it chops off the
https
part of it...How can I make the ingress open both ports and have it working on http and https?
I found this #1655 but AKS is not accepting
v1beta1
...The text was updated successfully, but these errors were encountered: