Closed davidfowl closed 8 months ago
Does DCP already support a way to disable proxying or will this require work there too?
I think that perhaps proxy support is a per endpoint option rather than a per resource option. So perhaps we could do something like this:
WithEndpoint(....other args..., bool? proxy = true)
@karolz-ms can comment on whether DCP still supports proxyless executables/containers.
Yes, DCP supports proxyless mode. It currently designed for singletons, but could be enhanced to support replicated services too.
@JamesNK
Giving this to you @JamesNK
I think the design here needs to be based on the resource itself being proxyless. It solves many of the ambiguities.
This issue outlines how networking works in aspire https://github.com/dotnet/docs-aspire/issues/232. Today we spin up a proxy for each endpoint which means the application being proxied needs to be amenable to accepting a port to listen on. The proxy is important for 2 reasons:
The scenario that does not work is the one described here https://github.com/dotnet/docs-aspire/issues/232#issuecomment-1884575748
In this scenario, there can be no proxy because the underlying process can't listen to anything but the port it already has. The only work around for this today is to avoid using WithEndpoint (formerly WithServiceBinding) but that breaks the ability to add references to other resources (WithReference) and it also means the dashboard doesn't show the url for the service.
Open questions: