diff options
Diffstat (limited to 'app.py')
-rw-r--r-- | app.py | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -4,7 +4,9 @@ import os # Snekchek -from flask import Flask, redirect +from flask import Flask +from flask import jsonify +from flask import redirect app = Flask(__name__) @@ -19,5 +21,15 @@ def index(): def invite(): return redirect("https://invite.pythondiscord.com/") [email protected]("/healthcheck") +def _healthcheck(): + return jsonify({"status":"ok"}) + + [email protected](404) +def _page_not_found(e): + return "replace me with a template, 404 not found", 404 + + if __name__ == '__main__': app.run(port=int(os.environ.get("WEBPAGE_PORT")), debug=False) |