Hosting ASP.NET Core as Windows service

前端 未结 7 1095
孤街浪徒
孤街浪徒 2020-12-04 08:43

As I get it in RC2 there\'s a support for hosting applications within Windows Services. I tried to test it on a simple web api project (using .NET Framework 4.6.1).

7条回答
  •  青春惊慌失措
    2020-12-04 09:29

    I found this topic while looking for a solution to a similar problem. Ended up implementing something that works pretty much like very (very) simplified Topshelf. You can easily run as console and/or install, uninstall and so one as a service. I think it can be pretty useful for somebody. You can find the code here : https://github.com/PeterKottas/DotNetCore.WindowsService and there's nuget here as well https://www.nuget.org/packages/PeterKottas.DotNetCore.WindowsService/ . Enjoy :)

提交回复
热议问题