Skip to content

Instantly share code, notes, and snippets.

@hotohoto
Last active August 7, 2018 07:19
Show Gist options
  • Save hotohoto/3da331008838223e2be2edde6f3a864d to your computer and use it in GitHub Desktop.
Save hotohoto/3da331008838223e2be2edde6f3a864d to your computer and use it in GitHub Desktop.
Run simple http server using python
import http.server
import socketserver
socketserver.TCPServer(("", 1234), http.server.SimpleHTTPRequestHandler).serve_forever()
@hotohoto
Copy link
Author

hotohoto commented Aug 7, 2018

This looks easier.

python -m SimpleHTTPServer 1234
python3 -m http.server 1234

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment