Created
May 13, 2015 02:37
-
-
Save davidrusu/602496aed9c17ac51e1d to your computer and use it in GitHub Desktop.
stateful server
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
from flask import Flask | |
import os | |
app = Flask(__name__) | |
seen = 0 | |
@app.route('/') | |
def hello(): | |
global seen | |
seen += 1 | |
return 'Hello world! seen: {}'.format(seen); | |
if __name__ == "__main__": | |
app.run(host="0.0.0.0", debug=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment