So basically I have a Blazor Server-Side application, which I published to folder using self-contained deployment and registered as Windows Service on Windows Server 2016, as I require the web app to start on boot and auto restart on crash - everything works fine, however I can't seem to find a way of how to create certificate so I could access HTTPS url, ex.: "https://192.162.10.10:5001/" ? At the moment the UseUrls() are set to HTTP as the service wouldn't start (or rather start and crash instantly) because of error:
Unable to configure HTTPS endpoint. No server certificate was specified, and the default developer certificate could not be found or is out of date.
To generate a developer certificate run 'dotnet dev-certs https'. To trust the certificate (Windows and macOS only) run 'dotnet dev-certs https --trust'.
I've tried using: https://github.com/natemcmaster/LettuceEncrypt - but with no luck. What are my options ? - Just manually signing a certificate on Windows Server and then specify path to cert in my web app and configure https for custom domain which points to Windows Server IP?