added monitoring endpoint
This commit is contained in:
@@ -34,6 +34,11 @@ def notify(config, message, var):
|
||||
return
|
||||
|
||||
|
||||
@app.route('/', methods=['GET'])
|
||||
def statuscheck():
|
||||
return jsonify(result=1)
|
||||
|
||||
|
||||
@app.route('/wakeup', methods=['POST'])
|
||||
def wakeup():
|
||||
if verifyapikey(request.values['apikey'], config):
|
||||
@@ -52,5 +57,5 @@ def wakeup():
|
||||
|
||||
if __name__ == '__main__':
|
||||
config = configparser.ConfigParser(interpolation=None)
|
||||
config.read('../config.ini')
|
||||
config.read('src/config.ini')
|
||||
app.run(host='0.0.0.0')
|
||||
Reference in New Issue
Block a user