I am trying to get websockets working through IIS and am running out of ideas.
- I have confirmed that the websockets windows feature is installed and setup in IIS.
- Websockets is enabled in IIS globally. I also tried breaking inheritance and setting it manually at the site level.
- I removed the load balancer and am hitting the server directly.
- Have tried over port 80 and 443 with ws and wss, same result.
- Do not see any related errors in the system or IIS logs.
It is also enabled in IIS.
I setup a hello world SignalR app where I set skipNegotiation to true and forced websockets in the javascript.
With this project I found that
- Websockets works locally, and on server when not run through IIS.
- The negotiate endpoint only returns websockets as an option if running locally or set to OutOfProcess in IIS. If InProcess in IIS it only returns LongPolling and SSE
- Tried setting up ARR to bypass IIS but that didn’t seem to work.
- Tried setting the app pool to different Managed Code settings.
I also setup this sample websockets projects.
- I found that the connection fails with error code 1006 and no reason.
- Tried disabling compression.
- Also tried disabling websockets in IIS and setting hosting model to OutOfProcess