def before_jail(self, args):
        from gevent.server import StreamServer

        self.host = self.config.get('geventserver.host', '0.0.0.0')
        self.ports = (int(x) for x in self.config['geventserver.ports'].split())
        log.info("Listening ports %r" % self.ports)

        self.server = None # this gets the last one to do a forever on

        for port in self.ports:
            self.server = StreamServer((self.host, port), handle)
            self.server.start()
dataset/ETHPy150Open zedshaw/python-lust/examples/gevent_server.py/Service.before_jail/original