How to install ssl certificate with Zpanel
This will be a straight forward instructional exercise on the most proficient method to introduce a SSL certificate in Linux with Zpanel installed
The tutorial shows how to install SSL Certificate with zPanel. You can utilize a self-marked SSL Certificate or purchase.
To begin with make ssl directory to simply maintain and proceed with the following commands
linuxtweaks ~]#mkdir /var/zpanel/hostdata/zadmin/ssl linuxtweaks ~]#cd /var/zpanel/hostdata/zadmin/ssl
If you want to install self-signed certificate first go through this link click here and generate your self signed certificate.
On the other hand in the event that you need to purchase an certificate, please submit domain_ssl.key to a SSL Provider, then you will get domain_ssl.crt and domain_ssl.ca-group records.
Assuming that you have the following
Now, go to zpanel admin login and go to Server Admin >> Module Admin >> Override a Virtual Host Setting >> Select a domain and click Select Vhost
On port override field, enter : 443
Check ‘Forward Port 80 to Overriden Port’ on the off chance that you need to dependably utilize HTTPS
Fill IP Override : Server’s IP Address or you can leave it blank.
Next, fill the custom entry with your trusted ssl certificate as shown in below image
SSLEngine On SSLCertificateFile /var/zpanel/hostdata/zadmin/ssl/domain_ssl.crt SSLCertificateKeyFile /var/zpanel/hostdata/zadmin/ssl/domain_ssl.key SSLCertificateChainFile /var/zpanel/hostdata/zadmin/ssl/domain_ssl.ca-bundle DocumentRoot "/var/zpanel/hostdata/zadmin/public_html/domain_directory"
Then final step is either wait for 2 minute or restart apache service by the following command.
linuxtweaks ~]#/etc/init.d/httpd restart
Thank you for sharing such a valuable trick. It’s really helpful for newbie.
Your welcome !!!
Hi, great. I’m going to try it on a server and I’ll tell you how it goes, a query, if I have more domains on the server, do I have to buy a certificate for each domain and do the same steps for each one?
Hi Thanks for reading the post.
Yes for every domain you have to repeat the same steps.
Hi, I read these posts to install an ssl that is free for an organization that is supporting a 100% ssh website. What do you think of that script to install will be enough for zpanel or do you have to do it as you indicate some suggestion?
SSL Enterprise: https://letsencrypt.org/
Yes letsencrypt is free ssl to use with any domain/subdomain.
You can use it for your website but the process will be different on zpanel/sentora control panel.
Your post led me on a wild goose chase. There is an error — or at least a mismatch with my Zpanel installation. The following is incorrect:
Server Admin >> Module Admin >> Override a Virtual Host Setting >> Select a domain and click Select Vhost
It should be:
Server Admin >> Module Admin >> Apache Config >> Override a Virtual Host Setting >> Select a domain and click Select Vhost
Thanks, I will see the post !