apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: hello-kubernetes-ingress
spec:
  ingressClassName: "nginx"
  rules:
    - host: "hw1.localhost"
      http:
        paths:
          - pathType: Prefix
            path: "/"
            backend:
              service:
                name: hello-kubernetes-first
                port:
                  number: 80
    - host: "hw2.localhost"
      http:
        paths:
          - pathType: Prefix
            path: "/"
            backend:
              service:
                name: hello-kubernetes-second
                port:
                  number: 80
