feat: Add index status to webserver
This commit is contained in:
parent
879f20f1e7
commit
42f4a59797
5
main.py
5
main.py
@ -300,7 +300,10 @@ app = Flask(__name__)
|
|||||||
|
|
||||||
@app.route("/")
|
@app.route("/")
|
||||||
def ping():
|
def ping():
|
||||||
return jsonify({"status": "OK"})
|
return jsonify({"status": "OK",
|
||||||
|
"height": getNodeHeight(),
|
||||||
|
"indexed": getNewestBlock()
|
||||||
|
})
|
||||||
|
|
||||||
def run_server():
|
def run_server():
|
||||||
app.run(host='0.0.0.0', port=3000)
|
app.run(host='0.0.0.0', port=3000)
|
||||||
|
Loading…
Reference in New Issue
Block a user