The installation of a Windows Service, especially for .NET Core (at least at the time of writing), is a very manual process. Furthermore, because we are using a configuration file, we'll need to make some slight tweaks so that the service will know where to look for the config file.
Installing the Windows Service
Code changes
When we install the service, we'll need to tell it where to look for the config file. We can do that by simply passing the parameter into the service. There are actually two ways to do this; the first (and the one that we're interested in) is to pass the parameter in during the installation of the service. This gets passed into the Main method. The second is passed in via the service management...