summaryrefslogtreecommitdiff
path: root/ostree-repo-server
blob: e6dc4a5663111c940f98ac7dceedb23e098f0da9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/usr/bin/python

from BaseHTTPServer import HTTPServer
from SimpleHTTPServer import SimpleHTTPRequestHandler 
from SocketServer import ThreadingMixIn

class ThreadedHTTPServer(ThreadingMixIn, HTTPServer):
    """Handle requests in a separate thread"""

handler = SimpleHTTPRequestHandler
handler.protocol_version="HTTP/1.0"
server_address = ('', 12324)

httpd = ThreadedHTTPServer(server_address, handler)
httpd.serve_forever()