Can not see my service under services after installing with Topshelf
sc
in powershell is the alias for set-Content
cmdlet use sc.exe
instead.
Try this (not tested)
sc.exe create "MyExecutable.Daemon" binPath="C:\'Program Files (x86)'\MyExecutable.Daemon.exe" DisplayName="MyExecutable.Daemon" start=auto
You should do MyExecutable.Daemon install start
. I think I've done that successfully from a PowerShell prompt before but I guess I would have to verify. If that doesn't work, you need to enable logging with one of the logging plugins and provide the log file. You shouldn't use sc
to install a Topshelf service. That will fail.