voyagermesh / voyager

🚀 Secure L7/L4 (HAProxy) Ingress Controller for Kubernetes
https://voyagermesh.com
Apache License 2.0
1.35k stars 134 forks source link

Dynamic Ingress in Kubernetes #1399

Open mcortinas opened 5 years ago

mcortinas commented 5 years ago

Hi, Currently we use voyager as a ingress controller but we need configure backend rules dinamically. I read datawire/ambassador project can do it, let me share this link to the documentation Let me also share this another link to short blog

I think this will be useful for voyager. Let me add an example, currently we can do this:

kind: Ingress
metadata:
  name: ingress-controller-name1
  namespace: ingress-voyager
  annotations:
    kubernetes.io/ingress.class: voyager
spec:
  rules:
  - host: service1.FQDN 
    http:
      paths:
      - path: /
        backend:
          serviceName: endpoint.service1
          servicePort: '80'

This will be very useful if we can set backend rules dynamically FROM the services like this instead of the ingress definition.

apiVersion: v1
kind: Service
metadata:
  name: endpoint
  namespace: service1
  annotations:
    service.appscode.com/ingress-registration: "ingress-controller-name1"
    service.appscode.com/ingress-namespace-registration: "ingress-voyager"
    service.appscode.com/backend-rule-host: "service1.FQDN"
    service.appscode.com/backend-rule-path: "/"
    service.appscode.com/backend-rule-backend-serviceName: "endpoint.service1"
    service.appscode.com/backend-rule-backend-servicePort: "80"
spec:
  type: ClusterIP
  ports:
    - port: 80

Best, Marc

SaschaHeyer commented 4 years ago

Agree this would be very useful. Any update on that?