fix(wrapper): addded proper mimeMap and ws suppoer
This commit is contained in:
@@ -1,16 +1,14 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<configuration>
|
<configuration>
|
||||||
<system.webServer>
|
<system.webServer>
|
||||||
<!-- Enable WebSockets -->
|
<!-- Enable WebSockets (may require unlocking at host level) -->
|
||||||
<webSocket enabled="true" receiveBufferLimit="4194304" pingInterval="00:01:00" />
|
<webSocket enabled="true" receiveBufferLimit="4194304" pingInterval="00:01:00" />
|
||||||
|
|
||||||
<rewrite>
|
<rewrite>
|
||||||
<rules>
|
<rules>
|
||||||
<!-- Proxy all requests starting with /lst/ to the .NET wrapper (port 4000) -->
|
|
||||||
<rule name="Proxy to Wrapper" stopProcessing="true">
|
<rule name="Proxy to Wrapper" stopProcessing="true">
|
||||||
<match url="^lst/(.*)" />
|
<match url="^lst/(.*)" />
|
||||||
<conditions>
|
<conditions>
|
||||||
<!-- Skip this rule if it's a WebSocket request -->
|
|
||||||
<add input="{HTTP_UPGRADE}" pattern="^WebSocket$" negate="true" />
|
<add input="{HTTP_UPGRADE}" pattern="^WebSocket$" negate="true" />
|
||||||
</conditions>
|
</conditions>
|
||||||
<action type="Rewrite" url="http://localhost:4000/{R:1}" />
|
<action type="Rewrite" url="http://localhost:4000/{R:1}" />
|
||||||
@@ -23,18 +21,25 @@
|
|||||||
</rewrite>
|
</rewrite>
|
||||||
|
|
||||||
<staticContent>
|
<staticContent>
|
||||||
|
<remove fileExtension=".js" />
|
||||||
<mimeMap fileExtension=".js" mimeType="application/javascript" />
|
<mimeMap fileExtension=".js" mimeType="application/javascript" />
|
||||||
|
<remove fileExtension=".mjs" />
|
||||||
<mimeMap fileExtension=".mjs" mimeType="application/javascript" />
|
<mimeMap fileExtension=".mjs" mimeType="application/javascript" />
|
||||||
|
<remove fileExtension=".css" />
|
||||||
<mimeMap fileExtension=".css" mimeType="text/css" />
|
<mimeMap fileExtension=".css" mimeType="text/css" />
|
||||||
|
<remove fileExtension=".svg" />
|
||||||
<mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
|
<mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
|
||||||
</staticContent>
|
</staticContent>
|
||||||
|
|
||||||
<handlers>
|
<handlers>
|
||||||
<!-- Let AspNetCoreModule handle all requests -->
|
|
||||||
<remove name="WebSocketHandler" />
|
<remove name="WebSocketHandler" />
|
||||||
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
|
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
|
||||||
</handlers>
|
</handlers>
|
||||||
|
|
||||||
<aspNetCore processPath="dotnet" arguments=".\lstWrapper.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
|
<aspNetCore processPath="dotnet"
|
||||||
|
arguments=".\lstWrapper.dll"
|
||||||
|
stdoutLogEnabled="false"
|
||||||
|
stdoutLogFile=".\logs\stdout"
|
||||||
|
hostingModel="inprocess" />
|
||||||
</system.webServer>
|
</system.webServer>
|
||||||
</configuration>
|
</configuration>
|
||||||
Reference in New Issue
Block a user