Пример #1
0
    cfg.StrOpt('auth_strategy', default='keystone'),
    cfg.StrOpt('core_plugin'),
    cfg.ListOpt('service_plugins',
                default=[]),
    cfg.StrOpt('base_mac', default="fa:16:3e:00:00:00"),
    cfg.IntOpt('mac_generation_retries', default=16),
    cfg.BoolOpt('allow_bulk', default=True),
    cfg.IntOpt('max_dns_nameservers', default=5),
    cfg.IntOpt('max_subnet_host_routes', default=20),
    cfg.StrOpt('state_path', default='/var/lib/quantum'),
    cfg.IntOpt('dhcp_lease_duration', default=120),
    cfg.BoolOpt('allow_overlapping_ips', default=False),
    cfg.StrOpt('control_exchange',
               default='quantum',
               help='AMQP exchange to connect to if using RabbitMQ or Qpid'),
    cfg.StrOpt('host', default=utils.get_hostname()),
    cfg.BoolOpt('force_gateway_on_subnet', default=False,
                help=_("Ensure that configured gateway is on subnet")),
]

# Register the configuration options
cfg.CONF.register_opts(core_opts)


def parse(args):
    cfg.CONF(args=args, project='quantum',
             version='%%prog %s' % quantum_version.version_string_with_vcs())

    # Validate that the base_mac is of the correct format
    msg = attributes._validate_regex(cfg.CONF.base_mac,
                                     attributes.MAC_PATTERN)
Пример #2
0
    cfg.StrOpt(
        "servers",
        default="localhost:8800",
        help=_("A comma separated list of servers and port numbers " "to proxy request to."),
    ),
    cfg.StrOpt("server_auth", default="username:password", secret=True, help=_("Server authentication")),
    cfg.BoolOpt("server_ssl", default=False, help=_("Use SSL to connect")),
    cfg.BoolOpt("sync_data", default=False, help=_("Sync data on connect")),
    cfg.IntOpt(
        "server_timeout",
        default=10,
        help=_("Maximum number of seconds to wait for proxy request " "to connect and complete."),
    ),
    cfg.StrOpt(
        "quantum_id",
        default="Quantum-" + utils.get_hostname(),
        help=_("User defined identifier for this Quantum deployment"),
    ),
    cfg.BoolOpt(
        "add_meta_server_route",
        default=True,
        help=_("Flag to decide if a route to the metadata server " "should be injected into the VM"),
    ),
]


cfg.CONF.register_opts(restproxy_opts, "RESTPROXY")


# The following are used to invoke the API on the external controller
NET_RESOURCE_PATH = "/tenants/%s/networks"
Пример #3
0
               help=_("Maximum number of host routes per subnet")),
    cfg.IntOpt('max_fixed_ips_per_port',
               default=5,
               help=_("Maximum number of fixed ips per port")),
    cfg.IntOpt('dhcp_lease_duration',
               default=120,
               help=_("DHCP lease duration")),
    cfg.BoolOpt('dhcp_agent_notification',
                default=True,
                help=_("Allow sending resource operation"
                       " notification to DHCP agent")),
    cfg.BoolOpt('allow_overlapping_ips',
                default=False,
                help=_("Allow overlapping IP support in Quantum")),
    cfg.StrOpt('host',
               default=utils.get_hostname(),
               help=_("The hostname Quantum is running on")),
    cfg.BoolOpt('force_gateway_on_subnet',
                default=False,
                help=_("Ensure that configured gateway is on subnet")),
]

core_cli_opts = [
    cfg.StrOpt('state_path', default='/var/lib/quantum'),
]

# Register the configuration options
cfg.CONF.register_opts(core_opts)
cfg.CONF.register_cli_opts(core_cli_opts)

# Ensure that the control exchange is set correctly
Пример #4
0
    cfg.StrOpt('auth_strategy', default='keystone'),
    cfg.StrOpt('core_plugin',
               default='quantum.plugins.sample.SamplePlugin.FakePlugin'),
    cfg.ListOpt('service_plugins', default=[]),
    cfg.StrOpt('base_mac', default="fa:16:3e:00:00:00"),
    cfg.IntOpt('mac_generation_retries', default=16),
    cfg.BoolOpt('allow_bulk', default=True),
    cfg.IntOpt('max_dns_nameservers', default=5),
    cfg.IntOpt('max_subnet_host_routes', default=20),
    cfg.StrOpt('state_path', default='/var/lib/quantum'),
    cfg.IntOpt('dhcp_lease_duration', default=120),
    cfg.BoolOpt('allow_overlapping_ips', default=False),
    cfg.StrOpt('control_exchange',
               default='quantum',
               help='AMQP exchange to connect to if using RabbitMQ or Qpid'),
    cfg.StrOpt('host', default=utils.get_hostname()),
]

# Register the configuration options
cfg.CONF.register_opts(core_opts)


def parse(args):
    cfg.CONF(args=args,
             project='quantum',
             version='%%prog %s' % quantum_version.version_string_with_vcs())

    # Validate that the base_mac is of the correct format
    msg = attributes._validate_regex(cfg.CONF.base_mac, attributes.MAC_PATTERN)
    if msg:
        msg = "Base MAC: %s" % msg