据我了解,当 web.config 配置不正确时,就会发生此错误。但是,当我发布应用程序时,会生成以下 web.config
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<location path="." inheritInChildApplications="false">
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath=".\Lotus.Server.exe" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
</system.webServer>
</location>
</configuration>
<!--ProjectGuid: 85a43eb6-3576-401d-b025-a15a2cc377b6-->
Run Code Online (Sandbox Code Playgroud)
我首先想到安装URL Rewrite,但这并没有解决问题。我压力很大,几乎尝试了所有方法,有什么解决办法吗?
错误页面如下所示: