Enable SSL on Virtualmin Nginx Server: Generating CSR

Virtualmin gives an easy option to enable SSL for your website. It’s a matter of few clicks to serve your website over https instead of http. I’ve previously posted tutorials explaining how to configure an unmanaged VPS with Virtualmin and Nginx. This post will explain how to enable SSL for a website hosted on Virtualmin-Nginx server.

Virtualmin also offer an option to enable self-signed SSL certificate which can be done in matter of few minutes. But web browsers still going to display a warning even though the connection is secure. You need a Signed certificate to avoid this. A signed certificate is going to cost you money. And it might take days to obtain one since there is a verification process for some certificates.

I am going to assume that you’ve already setup your VPS with Virtualmin and Nginx. And created your first Virtual Server with a valid domain name.

You need to submit a Certificate Signing Request (CSR) to signing authority while requesting a signed certificate. You can create a CSR by going to Virtualmin > Server Configuration > Manage SSL Certificate under the domain name you’re enabling SSL for. Now go to Create Signing Request tab and you’ll see following form.

I’ve filled the form with demo content. You should fill it with accurate information since certificate signing authority will ask you for the same information and they both should match. You can fill in your domain without www on Server name field and optionally have domain with www in the Other domain names field. With all the fields filled with accurate information, click Generate csr now button. Page will refresh and you’ll be presented with a page similar to following image.

You must save both the CSR and the key to a text file since you might need it in the future. You’re now ready to order an SSL certificate for your domain name. You can follow my instructions to buy an SSL certificate from NameCheap. Some authorities issue certificates immediately while others take days. Either way they’ll send some files once your SSL certificates is approved. Virtualmin will need those files to continue further.


Hey!! I'm Tharindu. I'm from Sri Lanka. I'm a part time freelancer and this is my blog where I write about everything I think might be useful to readers. If you read a tutorial here and want to hire me, contact me here.

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button