Add /health endpoint, disable debug (v0.1.1)
This commit is contained in:
+7
-2
@@ -1,7 +1,7 @@
|
|||||||
from flask import Flask, render_template
|
from flask import Flask, render_template
|
||||||
|
|
||||||
|
|
||||||
VERSION = "0.1.0"
|
VERSION = "0.1.1"
|
||||||
|
|
||||||
app = Flask(__name__, template_folder="templates", static_folder="static")
|
app = Flask(__name__, template_folder="templates", static_folder="static")
|
||||||
|
|
||||||
@@ -11,5 +11,10 @@ def index():
|
|||||||
return render_template("index.html", version=VERSION)
|
return render_template("index.html", version=VERSION)
|
||||||
|
|
||||||
|
|
||||||
|
@app.route("/health")
|
||||||
|
def health():
|
||||||
|
return "ok", 200
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app.run(debug=True, host="0.0.0.0", port=5000)
|
app.run(debug=False, host="0.0.0.0", port=5000)
|
||||||
Reference in New Issue
Block a user