asp.net MVC核心项目中的web.config [英] web.config in asp.net MVC core Project

查看:253
本文介绍了asp.net MVC核心项目中的web.config的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我真的是Asp.net MVC核心的新手,我的Visual Studio在macOS上,所以我不得不在Azure上发布我的项目.我想在Godaddy主机上转移此项目.我下载文件并上传到Godaddy主机上.问题是它有错误500.我能做些什么来解决它吗?

I am really new to Asp.net MVC core , my visual studio is on macOS , so I had to publish my project on Azure. I wanted to transfer this project on Godaddy host. I download the files and uploaded on the Godaddy host. the problem is that it has Error 500. Is there any thing which I can do to fix it?

这是我的webconfig,

here is my webconfig ,

<?xml version="1.0" encoding="utf-8"?>
<configuration>
   <system.webServer>
     <handlers>
      <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
      <aspNetCore processPath="dotnet" arguments=".\WebAppEver.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" />
  </system.webServer>
  </configuration>
  <!--ProjectGuid: F0AEADEA-9B69-4295-85F3-A3BDD9433AD4-->

推荐答案

您的主机将需要设置其服务器以支持asp.net核心.他们必须安装支持asp.net核心的IIS模块,并允许运行asp.net核心应用程序的额外过程.

Your host will need to setup their servers to support asp.net core. They must install the IIS module that supports asp.net core and allow the extra process to run that’s the asp.net core application.

您还需要知道安装了什么版本的asp.net core,或者您应该部署自托管版本.

You will also need to know what version of asp.net core is installed, or you should deploy a self hosted version.

对于我们的共享托管计划,我们不提供asp .NET core 1或2.最好的情况是根据要求获得一台支持asp .NET core 2.0的服务器.这需要任何运行Plesk Onyx 17.8的VPS或专用环境来自动支持安装程序.

For our shared hosting plans we do not offer asp .NET core 1 or 2. Best case is to get a server per the requirements to support asp .NET core 2.0. This requires any VPS or Dedicated environments running Plesk Onyx 17.8 for automated installer support.

此外,为了查看详细的错误消息,请将其添加到您的web.config:

Also, in order to see the detailed error message, add this to your web.config:

<configuration>
  <system.webServer>
      <httpErrors errorMode="Detailed"/>
  </system.webServer>
</configuration>

这篇关于asp.net MVC核心项目中的web.config的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆