duck-booking-tool/app.py

20 lines
514 B
Python
Raw Normal View History

2016-10-27 18:18:02 +00:00
#!/usr/bin/env python3
2016-10-28 02:17:03 +00:00
import os
2016-10-27 18:18:02 +00:00
import connexion
2016-10-28 02:17:03 +00:00
import sqlalchemy
from sqlalchemy import create_engine, Column, Integer, String
from sqlalchemy.ext.declarative import declarative_base
engine = create_engine( os.environ.get( 'DATABASE_URL', 'sqlite:///:memory:' ), echo=True )
2016-10-27 18:18:02 +00:00
app = connexion.App(__name__, specification_dir='./swagger/')
app.add_api('swagger.yaml',
arguments={
'title': 'Rubber Duck Booking Tool'
})
2016-10-27 18:18:02 +00:00
if __name__ == '__main__':
app.run(port=8080)