示例#1
0
def main():
    CONF(sys.argv[1:], project='oslo')
    logging.setup("oslo")

    with contextlib.closing(impl_zmq.ZmqProxy(CONF)) as reactor:
        reactor.consume_in_thread()
        reactor.wait()
示例#2
0
def main():
    CONF(sys.argv[1:], project='oslo')
    logging.setup("oslo")

    with contextlib.closing(impl_zmq.ZmqProxy(CONF)) as reactor:
        reactor.consume_in_thread()
        reactor.wait()
示例#3
0
文件: api.py 项目: lihuiba/volt
def main():
    CONF(sys.argv[1:], project='volt',
         version=version.version_string())
    logging.setup('volt')

    # Use the wsgi service to serve the request from client
    server = wsgi.Server('volt-api')
    server.start(CONF.bind_port)
    server.wait()
示例#4
0
文件: api.py 项目: vmthunder/volt
def main():
    conf_file = ["--config-file=/etc/volt/volt.conf"]
    if len(sys.argv) > 1:
        conf_file = sys.argv[1:]
    CONF(conf_file, project='volt', version=version.version_string())
    logging.setup('volt')

    # Use the wsgi service to serve the request from client
    server = wsgi.Server('volt-api')
    server.start(CONF.bind_port)
    server.wait()
示例#5
0
文件: api.py 项目: vmthunder/volt
def main():
    conf_file = ["--config-file=/etc/volt/volt.conf"]
    if len(sys.argv) > 1:
        conf_file = sys.argv[1:]
    CONF(conf_file, project='volt',
         version=version.version_string())
    logging.setup('volt')

    # Use the wsgi service to serve the request from client
    server = wsgi.Server('volt-api')
    server.start(CONF.bind_port)
    server.wait()
示例#6
0
def prepare_service(argv=None):
    #
    gettextutils.install('volt', lazy=True)
    cfg.set_defaults(log.log_opts,
                     default_log_levels=[
                         'amqplib=WARN', 'qpid.messaging=INFO',
                         'sqlalchemy=WARN', 'keystoneclient=INFO',
                         'stevedore=INFO', 'eventlet.wsgi.server=WARN',
                         'iso8601=WARN'
                     ])
    if argv is None:
        argv = sys.argv
    cfg.CONF(argv[1:], project='volt', version=version.version_string())
    log.setup('volt')
示例#7
0
文件: service.py 项目: lihuiba/volt
def prepare_service(argv=None):
    #
    gettextutils.install('volt', lazy=True)
    cfg.set_defaults(log.log_opts,
                     default_log_levels=['amqplib=WARN',
                                         'qpid.messaging=INFO',
                                         'sqlalchemy=WARN',
                                         'keystoneclient=INFO',
                                         'stevedore=INFO',
                                         'eventlet.wsgi.server=WARN',
                                         'iso8601=WARN'
                                         ])
    if argv is None:
        argv = sys.argv
    cfg.CONF(argv[1:], project='volt',
             version=version.version_string())
    log.setup('volt')