Running SSL locally on a hosts redirected domain name with Ubuntu and Apache
- by Matthew Brown
I recently made some changes to my Ubuntu computer so that a domain name resolved to my local copy of Apache.
I edited /etc/hosts and added
127.0.0.1 thisbit.example.com
Then set up a VirtualHost for the responses I wishes to create.
That all works fine and my testing is now shooting on ahead without harm or risk tot he production server.
Now for my next trick I need to test the authentication and so need to do this with HTTPS
Basically https://auth.example.com needs to work on my PC without the SSL causing an issue which I imagine would be the case as I am clearly not the true https://auth.example.com but for the basis of this exercise I need to pretend that I am. Now it might be that the Apps I'm testing don't worry about checking the certificate. (Many are in Java which I'm no expert with).
What gotchas am I likely to encounter and what is the best way of not letting my own hacks spoil my testing?
I'm guessing the place to start is to enable SSL with Apcahe... I've never done that before as it has never come up before.