Servage Magazine

Information about YOUR hosting company – where we give you a clear picture of what we think and do!

Using SSL for your local development

Thursday, May 19th, 2011 by Servage

In this previous article I showed how you can use local domains (like aproject.local and beeproject.local) for development on your local host. Today I am going to show how you can use SSL for your local development as well. I.e. using https:// instead of http:// for encrypted connections to your local development projects. Every serious and trustworthy website uses SSL encryption to secure sensitive data from third parties. This might just as well be a part of the development process.

First, you need to make sure that your webserver us ready to run with SSL. I have previously discussed two good options to get a local development system up and running quickly. Both are having SSL capability out of the box. These tips are for Apache webserver.

For MAMP on Mac, please refer to the configuration files /Applications/MAMP/conf/apache/httpd.conf and ssl.conf. Ensure that the following is uncommented in the httpd.conf (it is done similarly in other Apache-based solutions like XAMPP):

LoadModule ssl_module modules/mod_ssl.so

The above loads the SSL module.

Include /Applications/MAMP/conf/apache/ssl.conf

The above includes the default SSL configuration for MAMP.

In the ssl.conf make sure you change the DocumentRoot to the correct path for your project:

DocumentRoot "/Applications/MAMP/htdocs_ssl"

Beware that Apache only supports one SSL domain per IP. So you need to add further IP’s to your system, or use a module that allows multiple SSL VirtualHosts per IP. There is some further reading on this topic here.

Using SSL for your local development, 4.3 out of 5 based on 3 ratings
Categories: Guides & Tutorials

Keywords:

You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

No comments yet (leave a comment)

You are welcome to initiate a conversation about this blog entry.

Leave a comment

You must be logged in to post a comment.