Skip to content

Instantly share code, notes, and snippets.

@cornet
Last active January 21, 2016 22:32
Show Gist options
  • Save cornet/5ea2c6315a06bbebf578 to your computer and use it in GitHub Desktop.
Save cornet/5ea2c6315a06bbebf578 to your computer and use it in GitHub Desktop.
Various ways of creating a static web server for testing on port 8080

Ruby

ruby -run -e httpd . -p 8080

PHP

php -S localhost:8080

Python 2.7

python -m SimpleHTTPServer 8080

Python 3

python -m http.server 8080

Node.js

npm install serv
serve -p 8080
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment