Deploying the ASP. NET MVC 5 project to Mono/jexus using Visual Studio 2015

Source: Internet
Author: User

The latest mono 4.4 has supported the operation of the ASP. NET MVC5 project, some students listened to the words on the cheerful pick up visual Studio 2015 created an MVC 5 project, and then deployed to mono, browsing under the discovery of a bunch of errors appear, Heart 10,000 grass mud horse Pentium come, this also called support, this problem is caused by Visual Studio, If you don't believe it, you can use the ASP. Xamarin.studio to create the project, the deployment process is very smooth, no problems encountered; This article is for you to solve this knot, how visual Studio 2015 takes care of cross-platform development of ASP. NET MVC 5 projects.

VS2015 create a new ASP. NET project (the target framework is. net4.5), select MVC, and change authentication to not apply authentication.

Compile, and publish to Jexus, to access it. The reported error message is as follows.

Could not find File "/var/www/mvcdemo/bin\roslyn\csc.exe". This line tells us that we can not find Roslyn C # compiler, the current version of the Mono compiler or mono MCs compiler, and did not complete to Roslyn This compiler upgrade work is in progress, in the near future will be unified use of Roslyn.

The solution to this problem is to use the Mono MCs compiler, right-click on the project to manage NuGet packages, open the manager, and sequentially uninstall the following two components:

L Microsoft.CodeDom.Providers.DotNetCompilerPlatform

L Microsoft.Net.Compilers

Re-release to Jexus, through the browser can see the fresh bootstrap interface, Mono 4.4.2 version of the current compatibility with MVC5 is quite good.

Other compatibility issues are windows/linux differences, such as case and path issues, such as System.Web.Webpages.dll, which are loaded from NuGet, and pages in the middle of several related DLLs are lowercase and need to be capitalized. Bootstrap a few front-end frame There are also some case-insensitive, some styles can not be displayed, I will jexus the case-insensitive to open the good.

In Jexus, you just need to/usr/jexus/jws this script file "Export mono_iomap= ..." The sentence before the "#" removed, you can not distinguish between the case.

[Email protected]/usr/jexus]# VI JWs

Deploying the ASP. NET MVC 5 project to Mono/jexus using Visual Studio 2015

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.