Skip to content

Instantly share code, notes, and snippets.

@leeyoungseok
Created August 19, 2020 02:54
Show Gist options
  • Save leeyoungseok/d19c079131c9c456f8fa7eb57d204fe7 to your computer and use it in GitHub Desktop.
Save leeyoungseok/d19c079131c9c456f8fa7eb57d204fe7 to your computer and use it in GitHub Desktop.
from http.server import HTTPServer, SimpleHTTPRequestHandler
import ssl
httpd = HTTPServer(('localhost', 9090), SimpleHTTPRequestHandler)
httpd.socket = ssl.wrap_socket (httpd.socket,
keyfile="./server.key",
certfile='./server.crt', server_side=True)
httpd.serve_forever()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment