Updated status page

- include travis build number
- renamed properties
- ELB version
- moved code all into health check
- changed health check to be on same URL for admin and api
This commit is contained in:
Martyn Inglis
2016-03-03 15:18:12 +00:00
parent b818e1a535
commit 24a9487a20
5 changed files with 45 additions and 53 deletions

View File

@@ -4,7 +4,7 @@ from __future__ import print_function
import os
from flask.ext.script import Manager, Server
from flask.ext.migrate import Migrate, MigrateCommand
from app import (create_app, db, get_api_version, get_db_version)
from app import (create_app, db)
application = create_app()
manager = Manager(application)
@@ -22,21 +22,5 @@ def list_routes():
print("{:10} {}".format(", ".join(rule.methods - set(['OPTIONS', 'HEAD'])), rule.rule))
@manager.command
def api_version():
"""
Retrieve the version of the api.
"""
return get_api_version()
@manager.command
def db_version():
"""
Retrieve the db version.
"""
return get_db_version()
if __name__ == '__main__':
manager.run()