This commit is contained in:
2021-01-16 19:47:34 +01:00
commit 9a907c3a8e
8 changed files with 310 additions and 0 deletions

16
server.py Normal file
View File

@ -0,0 +1,16 @@
import connexion
from flask_cors import CORS
from dbpool import createConnectionPool
# prepare database connections
createConnectionPool()
# instantiate the webservice
app = connexion.App(__name__)
app.add_api('swagger.yaml')
# CORSify it - otherwise Angular won't accept it
CORS(app.app)
# provide the webservice application to uwsgi
application = app.app