Skip to content
Snippets Groups Projects
Commit 53e6bbdf authored by David Trattnig's avatar David Trattnig
Browse files

Update app instatiation for use in Gunicorn.

parent 69210291
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/python3.7
# #
# Aura Engine # Aura Engine
...@@ -177,9 +178,6 @@ class EngineApi: ...@@ -177,9 +178,6 @@ class EngineApi:
""" """
Starts the API server. Starts the API server.
""" """
# TODO Extend to provide production-grade app server
# Set debug=False if you want to use your native IDE debugger # Set debug=False if you want to use your native IDE debugger
self.api.app.run(port=self.config.api_port, debug=False) self.api.app.run(port=self.config.api_port, debug=False)
...@@ -411,11 +409,13 @@ class ReportResource(Resource): ...@@ -411,11 +409,13 @@ class ReportResource(Resource):
#
# Initialization calls # Initialization calls
#
engine_api = EngineApi(config, api)
engine_api.generate_html()
if __name__ == "__main__": if __name__ == "__main__":
engine_api = EngineApi(config, api)
engine_api.generate_html()
engine_api.run() engine_api.run()
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment