Use VirtualService instead of deploying haproxy/nginx/traefik

Hi,
I’m working on ONAP, an opensource (big) project that’s currently deployed using helm on Kubernetes.

One of the component uses haproxy, which acts as reverse proxy:

  • it listens on 8080
  • some path goes to a service (with pods) (Service A)
  • all the other ones goes into another service (Service B).

I’ve created a virtual service doing the same but virtual services doesn’t have an IP address in kubernetes world and thus name is not resolved.

I’ve then created a service which sends everything to pods belonging to Service A with the same name as VirtualService and created a gateway which maps to the VirtualService.

Everything coming from outside the cluster works now fine (with the regex) but in cluster communication doesn’t work.

Is there a way to make it work? I would like to remove haproxy as all forwarded traffic by haproxy is seen as “PassThroughCluster”.

Regard