Open bbrendon opened 1 month ago
Is chocolatey constructing that plain HTTP URL, or is the server constructing a plain HTTP URL in response to some HTTPS request?
This could be relevant:
And this:
I think this explains it. This server will construct absolute URLs based on the request, which is the plain HTTP request forwarded from HAProxy.
This zero-config scheme I built doesn't work with a proxy, since the underlying server can't know the address of the proxy.
I think you would need to add some config to supply the URL root when using a proxy.
I suggest you send a PR that:
configureRoutes
. If null/undefined, the existing behavior is used where we deduce the URL root from the incoming request in formatPackages
.yargs
in our other JS projects) and a command-line argument in cli.js
to supply this config to configureRoutes
.
I spun this up and have haproxy forwarding to express. The SSL is on HAproxy, and express is running as http.
I added the haproxy URL using https as source to choco.
I get back :
Notice above the https is missing from the nuget line?
Any solutions?
I'm going to attempt an HTTP -> HTTPS redirect but that isn't the best solution.