0
0
Fork 0
mirror of https://github.com/alerta/alerta.git synced 2025-01-29 03:11:34 +00:00
alerta_alerta/bin/alerta-api
2013-10-22 14:34:31 +01:00

16 lines
435 B
Python
Executable file

#!/usr/bin/env python
from alerta.common import config
from alerta.common import log as logging
from alerta.api.v2 import app, Version
from alerta.common.api import ApiClient
LOG = logging.getLogger('alerta.api')
CONF = config.CONF
ApiClient() # set API variable ie. api_port
if __name__ == '__main__':
config.parse_args(version=Version)
logging.setup('alerta')
app.run(host='0.0.0.0', port=CONF.api_port, debug=True)