helm icon indicating copy to clipboard operation
helm copied to clipboard

No matches for kind "Ingress" in version "extensions/v1beta1" error in Lab 1

Open ytimocin opened this issue 2 years ago • 1 comments

Getting the following error while trying to run this command in the first lab: kubectl apply -f ingress.yaml

error: resource mapping not found for name: "guestbook-ingress" namespace: "" from "ingress.yaml": no matches for kind "Ingress" in version "extensions/v1beta1"
ensure CRDs are installed first

Here is the solution: https://stackoverflow.com/a/71580831

ytimocin avatar Sep 26 '22 23:09 ytimocin

Agree .. there is a solution

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: guestbook-ingress
  annotations:
    nginx.ingress.kubernetes.io/rewrite-target: / 
spec:
  rules:
  - host: frontend.minikube.local
    http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          service:
            name: frontend
            port:
              number: 80
  - host: backend.minikube.local
    http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          service:
            name: backend
            port:
              number: 80

theiwaz avatar Dec 14 '23 17:12 theiwaz