To enable SSL on your website first you need to install SSL on your server. Install SSL Certificates
Step 1: First edit ssl configuration file in the apache2 directory.
root@Tecoide:~# vim /etc/apache2/sites-available/default-ssl.conf
Add these lines:
<VirtualHost> ServerAdmin webmaster@localhost DocumentRoot /var/www/html Servername tecoide.com Serveralias www.tecoide.com </VirtualHost>
Change your SSL file location on these lines
SSLCertificateFile /etc/letsencrypt/live/tecoide.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/tecoide.com/privkey.pem
Step 2: Now link default ssl file as shown below and restart apache2 service.
root@Tecoide:~# ln -s /etc/apache2/sites-available/default-ssl.conf /etc/apache2/sites-enabled/000-default-ssl.conf root@Tecoide:~# systemctl restart apache2.service
Step 3: Run this command to enable ssl
root@Tecoide:~# a2enmod ssl
That’s it. You are done with your ssl configuration. Now open your URL with https://