I'm trying to use Ocelot as a gateway to a K8S cluster and ideally would like to use the readiness/liveness probes. But every way I try to get Ocelot to handle the probe's endpoint results in issues:
Is there a way to make Ocelot allow access to an endpoint residing within the same service?
I found out how to do this. It's actually very simple, you just inject the MVC middleware earlier in the pipeline than the Ocelot middleware, and MVC will handle requests to internal endpoints before Ocelot ever sees them.
app.UseMvc();
app.UseOcelot().Wait();