apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: farmdb-ingress
  annotations:
    cloud.google.com/load-balancer-type: "External"
    kubernetes.io/ingress.class: "gce"
    kubernetes.io/ingress.global-static-ip-name: cfcommon-ip-dev
    networking.gke.io/managed-certificates: farmdb-tls-cert

spec:
  rules:
  - host: farmdb-dev.climatefarmers.org
    http:
      paths:
      - path: /*
        pathType: ImplementationSpecific
        backend:
          service:
            name: farmdb-service
            port:
              number: 8000
      - path: /api/modelling/*
        pathType: ImplementationSpecific
        backend:
          service:
            name: soil-modelling-service
            port:
              number: 80
      - path: /api/monitoring/*
        pathType: ImplementationSpecific
        backend:
          service:
            name: soil-monitoring-service
            port:
              number: 80