Hello there,

Before read articles:

CA-signed SSL certificate and Installing it on OpenVPN

Checking whether the private key matches the certificate!

First off, make sure that you have uploaded the private key, issued certificate, and CA bundle to your server.

After you have installed apache2 server (Apache/2.4.7), follow these steps:

1- Enable Apache’s SSL mod

sudo a2enmod ssl

2- Go to /etc/apache2/sites-enabled and edit this file:


<IfModule mod_ssl.c>
 <VirtualHost *:443>
  ServerAdmin webmaster@localhost
  ServerName haytham.com
  ServerAlias hay.haytham.com

  DocumentRoot /var/www/html

  ErrorLog ${APACHE_LOG_DIR}/error.log
  CustomLog ${APACHE_LOG_DIR}/access.log combined

  #   Enable/Disable SSL for this virtual host.
  SSLEngine on
  SSLCertificateFile /home/ubuntu/cbb45671d6f4b4b6.crt
  SSLCertificateKeyFile /home/ubuntu/mykey.key
  SSLCertificateChainFile /home/ubuntu/gd_bundle-g2-g1.crt

  <FilesMatch "\.(cgi|shtml|phtml|php)$">

    SSLOptions +StdEnvVars


  <Directory /usr/lib/cgi-bin>

    SSLOptions +StdEnvVars


  BrowserMatch "MSIE [2-6]" \

    nokeepalive ssl-unclean-shutdown \

    downgrade-1.0 force-response-1.0

  # MSIE 7 and newer should be able to use keepalive

  BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown



3- Enable apache site/virtual host:

cd /etc/apache2/sites-enabled
sudo a2ensite default-ssl.conf

4- Restart the apache:

sudo service apache2 restart

You can also refer to this: https://ae.godaddy.com/help/apache-install-a-certificate-centos-5238

And you are almost done!