added SSL code for production