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()
def main(): config.parse_args(sys.argv) logging.setup("nova") global LOG LOG = logging.getLogger('nova.virt.baremetal.deploy_helper') app = BareMetalDeploy() srv = simple_server.make_server('', 10000, app) srv.serve_forever()
def prepare_service(argv=[]): rpc.set_defaults(control_exchange='ironic') cfg.set_defaults(log.log_opts, default_log_levels=[ 'amqplib=WARN', 'qpid.messaging=INFO', 'sqlalchemy=WARN', 'keystoneclient=INFO', 'stevedore=INFO', 'eventlet.wsgi.server=WARN' ]) cfg.CONF(argv[1:], project='ironic') log.setup('ironic')
def prepare_service(argv=[]): rpc.set_defaults(control_exchange='ironic') cfg.set_defaults(log.log_opts, default_log_levels=['amqplib=WARN', 'qpid.messaging=INFO', 'sqlalchemy=WARN', 'keystoneclient=INFO', 'stevedore=INFO', 'eventlet.wsgi.server=WARN' ]) cfg.CONF(argv[1:], project='ironic') log.setup('ironic')
def prepare_service(argv=[]): config.parse_args(argv) 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', 'paramiko=WARN', ]) log.setup('ironic')
def prepare_service(argv=[]): config.parse_args(argv) 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', 'paramiko=WARN', ]) log.setup('ironic')
def prepare_service(argv=[]): config.parse_args(argv) cfg.set_defaults(log.log_opts, default_log_levels=['amqp=WARN', 'amqplib=WARN', 'qpid.messaging=INFO', 'oslo.messaging=INFO', 'sqlalchemy=WARN', 'keystoneclient=INFO', 'stevedore=INFO', 'eventlet.wsgi.server=WARN', 'iso8601=WARN', 'paramiko=WARN', 'requests=WARN', 'neutronclient=WARN', 'glanceclient=WARN', 'ironic.openstack.common=WARN', ]) log.setup('ironic')
def prepare_service(argv=[]): config.parse_args(argv) cfg.set_defaults( log.log_opts, default_log_levels=[ "amqp=WARN", "amqplib=WARN", "qpid.messaging=INFO", "sqlalchemy=WARN", "keystoneclient=INFO", "stevedore=INFO", "eventlet.wsgi.server=WARN", "iso8601=WARN", "paramiko=WARN", "requests=WARN", "neutronclient=WARN", "glanceclient=WARN", "ironic.openstack.common=WARN", ], ) log.setup("ironic")
test_opts = [ cfg.StrOpt('sqlite_clean_db', default='clean.sqlite', help='File name of clean sqlite db'), ] CONF = cfg.CONF CONF.register_opts(test_opts) CONF.import_opt('connection', 'ironic.openstack.common.db.sqlalchemy.session', group='database') CONF.import_opt('sqlite_db', 'ironic.openstack.common.db.sqlalchemy.session') CONF.set_override('use_stderr', False) logging.setup('ironic') _DB_CACHE = None class Database(fixtures.Fixture): def __init__(self, db_session, db_migrate, sql_connection, sqlite_db, sqlite_clean_db): self.sql_connection = sql_connection self.sqlite_db = sqlite_db self.sqlite_clean_db = sqlite_clean_db self.engine = db_session.get_engine() self.engine.dispose() conn = self.engine.connect()
test_opts = [ cfg.StrOpt('sqlite_clean_db', default='clean.sqlite', help='File name of clean sqlite db.'), ] CONF = cfg.CONF CONF.register_opts(test_opts) CONF.import_opt('connection', 'ironic.openstack.common.db.options', group='database') CONF.import_opt('sqlite_db', 'ironic.openstack.common.db.options', group='database') CONF.set_override('use_stderr', False) logging.setup('ironic') _DB_CACHE = None class Database(fixtures.Fixture): def __init__(self, db_api, db_migrate, sql_connection, sqlite_db, sqlite_clean_db): self.sql_connection = sql_connection self.sqlite_db = sqlite_db self.sqlite_clean_db = sqlite_clean_db self.engine = db_api.get_engine() self.engine.dispose() conn = self.engine.connect()
from ironic.db.sqlalchemy import api as sqla_api from ironic.objects import base as objects_base from ironic.openstack.common import log as logging from ironic.tests import conf_fixture from ironic.tests import policy_fixture test_opts = [cfg.StrOpt("sqlite_clean_db", default="clean.sqlite", help="File name of clean sqlite db.")] CONF = cfg.CONF CONF.register_opts(test_opts) CONF.import_opt("connection", "ironic.openstack.common.db.options", group="database") CONF.import_opt("sqlite_db", "ironic.openstack.common.db.options", group="database") CONF.set_override("use_stderr", False) logging.setup("ironic") _DB_CACHE = None class Database(fixtures.Fixture): def __init__(self, db_api, db_migrate, sql_connection, sqlite_db, sqlite_clean_db): self.sql_connection = sql_connection self.sqlite_db = sqlite_db self.sqlite_clean_db = sqlite_clean_db self.engine = db_api.get_engine() self.engine.dispose() conn = self.engine.connect() if sql_connection == "sqlite://": self.setup_sqlite(db_migrate)