Monday, May 26, 2014

Run A Simple Webserver From Active Directory Of Your Mac

Problem I need to run a simple HTTP server to check whether my angular.js app is running perfectly as the example says. It just need to serve the file I need with no platform or security concerns. Solution By googling, I hit simple command from lifehacker.com that will make my life easier. From the terminal, traverse to the designated directory and type these: python -m SimpleHTTPServer 8000 The last portion of the command is the target port where our server will responds. We should set this new server on an empty port. Now I am ready to test my app. source