summaryrefslogtreecommitdiff
path: root/serve.py
diff options
context:
space:
mode:
authorhenriquelalves <henriquelalves@gmail.com>2025-05-11 14:37:53 +0300
committerhenriquelalves <henriquelalves@gmail.com>2025-05-11 14:37:53 +0300
commit4b62024145f031c401315292576541e594440cfc (patch)
treede7c1f7b16893c238095932adf41c85aa738f039 /serve.py
downloadgamejam-slgj-2025-4b62024145f031c401315292576541e594440cfc.tar.gz
gamejam-slgj-2025-4b62024145f031c401315292576541e594440cfc.tar.bz2
gamejam-slgj-2025-4b62024145f031c401315292576541e594440cfc.zip
first commit
Diffstat (limited to 'serve.py')
-rw-r--r--serve.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/serve.py b/serve.py
new file mode 100644
index 0000000..7097e76
--- /dev/null
+++ b/serve.py
@@ -0,0 +1,14 @@
+#!/usr/bin/env python3
+
+import http.server
+import socketserver
+
+PORT = 8080
+
+Handler = http.server.SimpleHTTPRequestHandler
+
+Handler.extensions_map[".wasm"] = "application/wasm"
+
+with socketserver.TCPServer(("", PORT), Handler) as httpd:
+ print("serving at port", PORT)
+ httpd.serve_forever()