弘帝企业智能建站系统交流平台

 找回密码
 立即注册
查看: 923|回复: 0

Development Mode Swapping to Development environment

[复制链接]
发表于 2024-1-5 15:56:56 | 显示全部楼层 |阅读模式
Development Mode Swapping to Development environment will display more detailed information about the error that occurred. The Development environment shouldn't be enabled for deployed applications. It can result in displaying sensitive information from exceptions to end users.

NET8发布时发生,方法:
修改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=".\Hondy.Chat.exe" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout">
        <environmentVariables>
           <environmentVariable name="ASPNETCORE_ENVRONMENT" value="Development" />
        </environmentVariables>

      </aspNetCore>
    </system.webServer>
  </location>
</configuration>
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|弘帝企业智能建站系统 ( 皖ICP备07503252号 )

GMT+8, 2024-11-1 08:10 , Processed in 0.053424 second(s), 16 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表