6

I used to develop my web-apps using ASP.NET 4.x and host them in full IIS already during development, because:

1) I use multi-tenancy (site1.me.local and site2.me.local point to my app) and IIS express can't handle that AFAIK
2) Most of the times I do not need a debugger -> I just (re)build my app and refresh the browser - restarting IIS Express and the VS debugger wastes some time

Now I tried my first web-app using ASP.NET 5 aka Core 1.0 and I wasn't able to get it to run in full IIS to continue using my known workflow. I found out I can start IIS Express without debugging and just rebuild to solve #2, but #1 is still open.

Is full IIS even supported for ASP.NET 5 / Core 1.0 during development? If so is there some documentation on how to set that up around?

All documentation for full IIS I found is for publishing, but not for development.

Christoph Fink
  • 22,727
  • 9
  • 68
  • 113
  • 2
    AFAIK , you can't use full IIS. IIS Express does support multitenancy! Currently we are developing a multi-tenant web app and we don't have any issues with iis express. You need to edit your host file and your applicationhost.config, and run vs2015 as admin. Check out: http://stackoverflow.com/questions/4709014/using-custom-domains-with-iis-express – regnauld Mar 12 '16 at 20:47
  • Any changes with this? What scenario is for developing on Core, press "debug" every time? – Ssss Aug 02 '16 at 12:09

2 Answers2

2

You may actually not event want to use IIS in development with Asp.Net Core. Asp.Net Core has been separated from IIS and even in production IIS will only act as a reverse proxy passing requests to your AspNet.Core application. Asp.Net Core uses Kestrel as an application server and it is much easier to use just this during development. To get a similar workflow you had before you would use dnx watch/dotnet watch during development which will watch code files of your application and if any of the files changes it will stop the application, rebuild the project and restart the application. This is when you can refresh the browser to see changes (note that this is even one less step that you had before where you had to rebuild the application yourself).

It still should be possible to use IIS for development if you really need it but if you don't have a specific scenario that requires IIS I don't think IIS for development will give you any benefits.

Pawel
  • 31,342
  • 4
  • 73
  • 104
  • 1
    It would be a must for ASP.NET Core development to work with full IIS. I think Microsoft will solve that gap soon. Many features cannot be tested on IIS Express, as it does not have concepts such as application pool. – Lex Li Apr 03 '16 at 04:07
  • I have not tried but it is possible that IIS will restart the Asp.NET Core app process if you touch your web.config file. If you use Visual Studio I think tooling can take care of this as well - again possibly it will just publish your application which will overwrite web.config which may restart Asp.NET Core app process as above (or just by using [app_offline.htm](https://github.com/aspnet/IISIntegration/issues/81)). Having said that - IMHO unless you use a specific feature of IIS not supported by Kestrel (e.g. windows auth) using IIS for development will be an overkill. – Pawel Apr 03 '16 at 06:29
1

The integration mode with full IIS has been changed several times (from Beta to RC1 and now to RC2), which messes up the documentation,

https://github.com/aspnet/Announcements/issues/164

You probably need to wait till RC2 is available to see the latest official steps.

Lex Li
  • 60,503
  • 9
  • 116
  • 147