apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: rusell-ingress-service
  annotations:
    kubernetes.io/ingress.class: nginx
    nginx.ingress.kubernetes.io/use-regex: "true"
    cert-manager.io/issuer: "letsencrypt-staging"
spec:
  tls:
    - hosts:
        - api.rusell.com
      secretName: rusell-tls
  rules:
    - host: api.rusell.com
      http:
        paths:
          - path: /api/addresses
            pathType: Prefix
            backend:
              service:
                name: rusell-addresses-service
                port:
                  number: 80
          - path: /api/bank-drafts
            pathType: Prefix
            backend:
              service:
                name: rusell-bank-drafts-service
                port:
                  number: 80
          - path: /api/clients
            pathType: Prefix
            backend:
              service:
                name: rusell-clients-service
                port:
                  number: 80
          - path: /api/companies
            pathType: Prefix
            backend:
              service:
                name: rusell-companies-service
                port:
                  number: 80
          - path: /api/employees
            pathType: Prefix
            backend:
              service:
                name: rusell-employees-service
                port:
                  number: 80
          - path: /api/parcels
            pathType: Prefix
            backend:
              service:
                name: rusell-parcels-service
                port:
                  number: 80
          - path: /api/routes
            pathType: Prefix
            backend:
              service:
                name: rusell-routes-service
                port:
                  number: 80
          - path: /api/tickets
            pathType: Prefix
            backend:
              service:
                name: rusell-tickets-service
                port:
                  number: 80
          - path: /api/transport-sheets
            pathType: Prefix
            backend:
              service:
                name: rusell-transport-sheets-service
                port:
                  number: 80
          - path: /api/vehicles
            pathType: Prefix
            backend:
              service:
                name: rusell-vehicles-service
                port:
                  number: 80
