done messing with python http server

This commit is contained in:
2020-11-09 17:26:36 +01:00
parent 81cfb5dd4e
commit a30531ec48
5 changed files with 559 additions and 0 deletions
+13
View File
@@ -0,0 +1,13 @@
#!/usr/bin/env python -m httpserver 8000
import http.server
import socketserver
PORT = 80
server = http.server.HTTPServer
Handler = http.server.CGIHTTPRequestHandler
Handler.cgi_directories = ["/"]
with server(("", PORT), Handler) as httpd:
print('serving at port', PORT)
httpd.serve_forever()