Skip to main content

Really simple python webserver for prototyping

Project description

Really really simple python webserver for prototyping. Basically just wraps SimpleHTTPServer/SimpleHTTPRequestHandler. I made this for my own purposes, but you’re welcome to use it.

Defaults to running on the port specified in the PORT environment variable, or 8080 if not defined.

Installation

pip install protoserver

The only function

protoserver.serve(directory = ".")

Example

import protoserver

protoserver.serve() # Serves from the current directory

Another example

import protoserver

protoserver.serve("static")  # Serves from ./static

Clone and run demo/demo.py if you need to see this in action.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

protoserver-0.1.2.tar.gz (1.1 kB view details)

Uploaded Source

File details

Details for the file protoserver-0.1.2.tar.gz.

File metadata

File hashes

Hashes for protoserver-0.1.2.tar.gz
Algorithm Hash digest
SHA256 a252bb69df872b1bf9111b0cb07f8e3d99f32c578ba902d81bd0bd75fb6bb409
MD5 68405ec65cbbb78d825b225590788e3e
BLAKE2b-256 edb34471445bd7e809881834f25f1c143f28f8fda609ea74de1b4e089b8093d5

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page