Closed bugproof closed 5 years ago
ServiceBase Run isn't async, there's nothing to do here. https://github.com/aspnet/Hosting/blob/f9d145887773e0c650e66165e0c61886153bcc0b/src/Microsoft.AspNetCore.Hosting.WindowsServices/WebHostWindowsServiceExtensions.cs#L38-L39
I'm using C# 7.1
async Task Main(string[] args)
. I wanted to convert my project into a Windows Service following this: https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/windows-service?view=aspnetcore-2.1In my
Program.Main
I'm usingawait webHost.RunAsync();
. I was hoping to have something likeawait webHost.RunAsServiceAsync()
. What should I do?