How to enable SSL on NGINX
Secure Sockets Layer (SSL) has become a necessity for web servers. Why? Because security has been forced into the spotlight, and every company now faces the fact that their web servers must serve up content securely.
To that end, you need to make use of SSL. If you happen to work with NGINX, you're in luck, as the process is quite possible (though slightly complicated).
I want to walk you through the steps of enabling SSL on a Ubuntu Server 18.04, running NGINX. I will demonstrate this with a self-signed certificate, but a certificate from an official Certificate Authority (CA) is a much better choice. In fact, you should use the self-signed certificate only as a means for testing purposes.
What you need
To accomplish this, you'll need NGINX running on Ubuntu Server 18.04, with a self-signed certificate at the ready. I'll assume you already have Ubuntu and NGINX up and running. We'll walk through the process of creating the self-signed certificate.