Welcome to the Linux Foundation Forum!

Exercise 7 - nginx update requires change to YAML

Hello,

This info may also help. The nginx folks had a breaking change 2 days ago:

https://github.com/kubernetes/ingress-nginx/releases/tag/controller-v1.0.0

If you miss the ingressclass the controller gives you:

"Ignoring ingress because of error while validating ingress class" ingress="default/ingress-test" error="ingress does not contain a valid IngressClass"

So a quick fix is adding the annotation for the ingress class to your ingress.yaml Otherwise the whole ingress part of lab 7 will not work.

  1. apiVersion: networking.k8s.io/v1
  2. kind: Ingress
  3. metadata:
  4. name: ingress-test
  5. namespace: default
  6. annotations:
  7. kubernetes.io/ingress.class: "nginx"
  8. spec:
  9. rules:
  10. - host: www.example.com
  11. http:
  12. paths:
  13. - backend:
  14. service:
  15. name: secondapp
  16. port:
  17. number: 80
  18. path: /
  19. pathType: ImplementationSpecific
  20. - host: thirdpage.org
  21. http:
  22. paths:
  23. - backend:
  24. service:
  25. name: thirdpage
  26. port:
  27. number: 80
  28. path: /
  29. pathType: ImplementationSpecific

Comments

  • Thank you for the updates. I was wondering what happened to my ingress.yaml. Although I followed every step in the "Exercise 7.2: Service Mesh and Ingress Controller", I was still getting "404 Not Found". Adding the mentioned annotation has solved my problem.

  • Same here, fortunately 'kubectl logs yingress-ingress-nginx-controller-xxxx' showed this message.

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