问题
Is there any one who can point me in the right direction?
When hosting my Blazor Client Side application to IIS the signalr is not working. In visual studio with IIS express it work as expected. I did setup IIS and deployed the application as indicated in the Microsoft documents.
There is no console errors and the hub returns status code 200 when hosting in IIS.
Thank you in advance
回答1:
Websocket support is not enabled by default on IIS. It was introduced in IIS 8, and has to be enabled from windows' optional features: https://docs.microsoft.com/en-us/iis/get-started/whats-new-in-iis-8/iis-80-websocket-protocol-support
Optional features -> IIS -> WWW services -> App Dev Features -> Websocket protocol
Disclaimer: I found this after asking a question about this myself, so I copied my answer from there: https://stackoverflow.com/a/61411666/4364057
来源:https://stackoverflow.com/questions/60283573/blazor-client-side-signalr-not-working-when-hosting-to-iis