0

In that ingress section of AKS, we can add routes to multiple application but all having container port as 80 only. With Ingress, our application is using port 8080. But with ingress, even if I keep servicePort as 8080, it is not working.

Like, adding routes to multiple apps with different ports for their service.

apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
  name: nginxapp1-ingress-service
spec:  
  rules:
  - http:
      paths:
      - path: /
        backend:
          serviceName: testing
          servicePort: 8080
Michael Hampton
  • 237,123
  • 42
  • 477
  • 940
Sara June
  • 389
  • 4
  • 15
  • Hello @SaraJune. Could you please add some information? - Which ingress controller are you using, spec of your pod/deployment, service. – Wytrzymały Wiktor Sep 28 '21 at 10:58
  • azure default one. I got reference from this https://github.com/stacksimplify/azure-aks-kubernetes-masterclass/tree/master/09-Ingress-Basic – Sara June Sep 29 '21 at 09:47
  • As I can see from [01-NginxApp1-Deployment.yml](https://github.com/stacksimplify/azure-aks-kubernetes-masterclass/blob/master/09-Ingress-Basic/kube-manifests/01-NginxApp1-Deployment.yml) and [02-NginxApp1-ClusterIP-Service.yml](https://github.com/stacksimplify/azure-aks-kubernetes-masterclass/blob/master/09-Ingress-Basic/kube-manifests/02-NginxApp1-ClusterIP-Service.yml) files, port: 80. Did you change it for your pod and service to 8080, since you try to use servicePort: 8080 in your Ingress? – Andrew Skorkin Oct 06 '21 at 10:49
  • Yeah I have done that, but still same issue. The container is 80, And the service I kept to 8080 with containerport 80 – Sara June Oct 07 '21 at 08:28
  • Sorry for delay. Have you solved this problem? – Andrew Skorkin Nov 26 '21 at 16:54

0 Answers0