How do I run a simple Python Server?

Nam Phong

New member
How do I run a simple Python Server?
Answer
To run the server:
  1. Open a terminal window.
  2. Navigate to the directory you want to have the root directory.
  3. Execute the command to start the server.
  4. Python 2 — python -m SimpleHTTPServer 8000.
  5. Python 3 — python -m http. server 8000.
 

Tìm kiếm

Back
Top