'Valid HTTPS certificate for dotnet development on localhost - Ubuntu

I need to test something which needs to be served over https and I believe the standard dotnet dev-certs https --trust doesnt work on Ubuntu.

I have tried generating my own certs via openssl and everything and just cannot get a trusted cert.

Any help would be greatly appreciated!



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source