Welcome to the Linux Foundation Forum!

Ingress controller: 11.2 getting this on both external and internal "503 Service Temporarily Unavai"

Hi Mr. @chrispokorni ,
I am having an error on both external and internal when using the below commands.
curl -H "Host: internal.org" http://10.97.192.168
curl -H "Host: www.external.com" http://10.97.192.168
I am unable to understand why it is not working kindly let me know about it if I am doing something wrong. I am sharing all my settings for exercise 11.2.

  1. mas1@mas1:~$ kubectl get all
  2. NAME READY STATUS RESTARTS AGE
  3. pod/myingress-ingress-nginx-controller-n48j7 2/2 Running 0 32m
  4. pod/myingress-ingress-nginx-controller-pvv6m 2/2 Running 0 33m
  5.  
  6. NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
  7. service/kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 21d
  8. service/myingress-ingress-nginx-controller LoadBalancer 10.97.192.168 <pending> 80:30989/TCP,443:32137/TCP 37m
  9. service/myingress-ingress-nginx-controller-admission ClusterIP 10.104.133.123 <none> 443/TCP 37m
  10.  
  11. NAME DESIRED CURRENT READY UP-TO-DATE AVAILABLE NODE SELECTOR AGE
  12. daemonset.apps/myingress-ingress-nginx-controller 2 2 2 2 2 kubernetes.io/os=linux 37m
  13.  
  14. NAME COMPLETIONS DURATION AGE
  15. job.batch/my-ingress-nginx-admission-patch 0/1 49m 49m
  1. mas1@mas1:~$ kubectl get svc
  2. NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
  3. kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 21d
  4. myingress-ingress-nginx-controller LoadBalancer 10.97.192.168 <pending> 80:30989/TCP,443:32137/TCP 39m
  5. myingress-ingress-nginx-controller-admission ClusterIP 10.104.133.123 <none> 443/TCP 39m

ingress.yaml:

  1. mas1@mas1:~$ kubectl get ingress ingress-test -o yaml
  2. apiVersion: networking.k8s.io/v1
  3. kind: Ingress
  4. metadata:
  5. annotations:
  6. kubernetes.io/ingress.class: nginx
  7. creationTimestamp: "2022-06-13T18:59:03Z"
  8. generation: 4
  9. name: ingress-test
  10. namespace: default
  11. resourceVersion: "123512"
  12. uid: 832fb732-0a52-410b-bc81-7a5141b0e175
  13. spec:
  14. rules:
  15. - host: internal.org
  16. http:
  17. paths:
  18. - backend:
  19. service:
  20. name: web-two
  21. port:
  22. number: 80
  23. path: /
  24. pathType: ImplementationSpecific
  25. - host: www.external.com
  26. http:
  27. paths:
  28. - backend:
  29. service:
  30. name: web-one
  31. port:
  32. number: 80
  33. path: /
  34. pathType: ImplementationSpecific
  35. status:
  36. loadBalancer: {}

And one last thing how do they get into the web-two- container even in both 11.1 and 11.2 there is no such thing where we have to create a pod having the container name web-two. Please kindly clear this too.

Best Answer

  • Posts: 2,453
    Answer ✓

    Hi @alihasanahmedk,

    It seems you may have missed step 1 of lab exercise 11.2. It outlines the backend deployments and services targeted by the ingress.

    Regards,

    -Chris

Answers

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Categories

Upcoming Training