How to Install SSL on VPS – SSL is one of the important parts of a website. SSL will serve as protection against everything that will enter and lead to the website. Maybe the beginners are still confused and doubt whether it is important to install SSL on the website. By installing SSL, you can avoid attacks that will enter the website. This time we will explain the tutorial on How to Install SSL on VPS which can be done easily. Next is the complete SSL install guide on VPS:
How to Install SSL on VPS, Easy and Fast Tutorial
Before installing SSL, there are several stages of preparation that you must do:
1. First, make sure you have ordered SSL first.
2. Prepare a CRT file (certificate), Private Key, Cabundle SSL. The three files were obtained when you paid off the SSL purchase invoice.
3. Next, make sure you can remote VPS via SSH. And also make sure you have a VPS first.
4. Know some of the commonly used Linux commands / commands. If not, please read and search for references first. If you have passed the four stages, please go to the steps below.
How to Install SSL on Apache Version VPS
The way to install SSL in Apache is very easy. Please follow the step by step below. Make sure the Apache web server is installed on your VPS first. If not, please install it first!
1. Activating SSL in Apache
• To enable SSL in Apache, please write :
a2 modm ssl
• Then don’t forget to restart Apache service by the method :
service Apache2 restarted
2. Creating an SSL Folder
• Now it’s time to create an SSL folder containing the .crt, .key and .cabundle files. Please enter the / etc / apache2 folder by the method :
cd / etc / apache2 /
• Then create a folder called “ssl” by the way :
• After that, go to the ssl folder and please create a .crt, .key and .ca-bund file using the touch command :
touch [FILE NAME] .crt
touch [NAME FILE] .key
touch [FILE NAME] .ca-bundle
• Remember! You have to make 3 files! So that later 3 files will appear as shown below. For free file names, please write as desired.
3. Copying .crt, .key and .ca-bundle files
• Prepare the .crt, .key and .ca-bund files immediately from your SSL. Then copy the three files one by one into the file. The method is please write :
nano [NAME FILE.crt]
• Then copy according to your .crt file.
* Note : If using nano, then right-click paste. Then save by pressing ctrl + x then press “Y” and enter.
4. Installing SSL
• The .crt, .key and .ca-bund files have been prepared. Now it’s time for you to direct the Apache to all three files. The way is :
cd / etc / apache2 / sites-enabled /
• Then look for the default-ssl.conf file. Later, you must edit the configuration in the file. To edit the configuration, please write :
• After that in the SSLCertificateFile, SSLCertificateKeyFile, and SSLCertificateChainFile sections are filled with the path (location) of each file :
SSLCertificateFile / etc / apache2 / ssl / [FILE NAME] .crt
SSLCertificateKeyFile / etc / apache2 / ssl / [NAME FILE] .key
SSLCertificateChainFile / etc / apache2 / ssl / [NAME FILE] .ca-bundle
• Don’t forget to remove the # sign (fence) before writing SSLCertificateFile, SSLCertificateKeyFile, and SSLCertificateChainFile.
• Then make sure you have activated SSLEngine. The trick is to remove the fence before the word SSLEngine.
5. Restart the Apache Service
• After all configurations have been entered in the default-ssl.conf file, it is time to restart the Apache service. Please write :
service Apache2 restarted
6. Checking SSL
• Now it’s time, you check whether SSL has been successfully installed or not. The command is :
openssl s_client -connect [NAME DOMAIN]: 443
• Details will appear as below. Make sure that there is an SSL provider name listed there. For example, the SSL used is Comodo PositiveSSL. Then provide “COMODO” writing in it will appear.
• Now how to install SSL on VPS with the Apache web server is complete.
For a tutorial on how to install SSL on a VPS, the Nginx version will be uploaded in the next article. Now, you can easily install SSL on your own VPS, right? Actually the SSL installation process on Apache and Nginx is the same. You only need to direct the three important SSL files such as certificate, public key and cabundle into the web server configuration. Hopefully all the information above can help you who will Install SSL on VPS and hope this information can be useful. Good luck!