Created
April 28, 2017 01:40
-
-
Save zweite/26e20623ba3a12f4fd497cbdbcc1e2fa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
web.py - specify address and port | |
""" | |
import web | |
class MyApplication(web.application): | |
def run(self, port=8080, *middleware): | |
func = self.wsgifunc(*middleware) | |
return web.httpserver.runsimple(func, ('0.0.0.0', port)) | |
if __name__ == "__main__": | |
app = MyApplication(urls, globals()) | |
app.run(port=8888) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment