import cherrypy
import bottle
from .pyapi import *

application = bottle.default_app()

cherrypy.config.update({'environment' : 'staging'})
cherrypy.config.update({
    'server.socket_host': "0.0.0.0",
    'server.socket_port': 6772,
    'engine.autoreload.on': True,
    'request.show_tracebacks': True,
    'request.show_mismatched_params': True,
    'log.screen': True,
})

cherrypy.tree.graft(application, "/")
cherrypy.engine.start()
cherrypy.engine.block()