Hosting Nop 4.40 in local IIS for development

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
2 years ago
Hey guys,

Up until now I've just been using IIS Express for hosting Nop locally for development, and it's been working fine.  I now need to use a custom domain name (so that I can install and use licensed plugins), so I tried to get Nop running in IIS proper (on Windows 10) but I'm having trouble.  I was hoping someone could point out where I've gone wrong.

Here's what I've done so far:

1. Installed ASP.NET Core 5.0 Runtime installer (and restarted machine)
2. Created a new site in IIS pointing to \src\Presentation\Nop.Web
3. Configured the application pool to have a .NET CLR version of 'No Managed Code' and to use 'Integrated pipeline mode'
4. Set the application pool to run under a new local admin account, which has SQL access
5. Set the HTTP and HTTPS bindings to use the custom domain
6. Set the custom domain to point to 127.0.0.1 in hosts file
7. In IIS server settings, set the Feature Delegation for Modules to be Read/Write (instead of Read only)
8. In the web.config file, set the processPath to be "dotnet" and the arguments to be ".\bin\Debug\net5.0\Nop.Web.dll"

When I try and access the site using the custom domain, the application is running (and the DB is being called), but I'm getting this error in the Event Viewer:

Category: Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware
Exception: System.InvalidOperationException: Cannot find compilation library location for package 'System.Drawing.Common'

I don't know if there's something funky going on with System.Drawing - I've tried to find a solution and it seems this kind of error has cropped up all over the place, but I don't know what I'm missing here.  This obviously works in IIS Express, so there must be some step I've missed for IIS.

Does anyone have a suggestion on what I could try next?

Thanks.
2 years ago
It does seem odd that the system runs OK, and yet you have event log error.  Be sure you do see the System.Drawing.dll in the site folder.

(P.S.  If you ask, some vendors will give you a license for their plugin for localhost.  We do ;)
2 years ago
Hey!  Sorry, I realise I didn't make it clear in my first message - the site doesn't load, I get a generic Nop error saying that something's gone wrong.

Good shout about a plugin though - I didn't think to check if something already exists for this.  I'll take a look - thanks.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.