1
0
mirror of https://github.com/avatao-content/test-tutorial-framework synced 2024-11-15 06:37:18 +00:00
test-tutorial-framework/solvable/src/tfw_server.py

21 lines
679 B
Python
Raw Normal View History

import sys
import zmq
2018-03-27 15:05:27 +00:00
import tornado
from tornado.ioloop import IOLoop
from sql_injection_fsm import SQLInjectionFSM
from tfw.networking.server.tfw_server import TFWServer
from tfw.config import TFWENV
from tfw.config.logs import logging
2018-03-27 15:09:14 +00:00
LOG = logging.getLogger(__name__)
if __name__ == '__main__':
2018-03-27 15:09:14 +00:00
TFWServer(SQLInjectionFSM).listen(TFWENV.WEB_PORT)
LOG.debug('Python version: %s', sys.version[:5])
LOG.debug('Tornado version: %s', tornado.version)
LOG.debug('ZeroMQ version: %s', zmq.zmq_version())
LOG.debug('PyZMQ version: %s', zmq.pyzmq_version())
LOG.info('Tornado application listening on port %s', TFWENV.WEB_PORT)
IOLoop.instance().start()