This article presumes that you have already downloaded the wild card certificate after generating the private key and csr request.
GoDaddy gives you two files:
- gd_bundle.crt
- yourdomain.com.crt
Step 1.
change httpd.conf file to create a virtualhost for https at port 443 as following.
<VirtualHost xxx.xxx.xxx.xxx:443>
DocumentRoot "/home/path/web/root/folder"
ServerName subdomain.yourdomain.com:443
RewriteEngine On
SSLEngine on
SSLCertificateFile /home/path/to/yourdomain.com.crt
SSLCertificateKeyFile /home/path/to/privatekey.key
SSLCertificateChainFile /home/path/to/gd_bundle.crt
#SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
</VirtualHost>
As we know above that wild card certificate secures multiple sub domain so use *.yourdomain.com:443, in your case replace * with your sub domain.
To use SSLEngine on you need to enable ssl module in apache. Use following command:
sudo a2enmod ssl
Step 2
Change .htaccess file as
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://your.domain.com/$1 [R,L]
Above code chunk is used to redirect the traffic to https url. Restart your server. And it should work.
While copy pasting the code above please take care special characters (would be better if typed). would integrate a code highlighting plugin soon in my blog. Lazy me.
-deepak


