4
votes

Just made a http server handling only file uploading. Want to add a feature to the http server sharing the file on Get request by a http client.

I have no idea how to show the file to clients. So a client can see it using http://127.0.0.1/filename.avi

In summary

A http client is uploading a file to a http server.

A http client is watching the file through the http server

3

3 Answers

7
votes

Python 2: SimpleHTTPServer.

python2 -m SimpleHTTPServer 80

Python 3: http.server.

python -m http.server 80

0
votes

You can look at Flask. It is very lightweight and probably does most of what you're looking for.

0
votes

new python would be python -m http.server [port number] in the command prompt