def spawn_kube_manager(cls, extra_args=()): kube_config = [ ('DEFAULTS', 'log_file', 'contrail-kube-manager.log'), ('DEFAULTS', 'logger_class', test_common.ErrorInterceptingLogger.get_qualified_name()), ('DEFAULTS', 'nested_mode', '0'), ('DEFAULTS', 'kube_timer_interval', '0'), ('VNC', 'vnc_endpoint_ip', cls._api_server_ip), ('VNC', 'vnc_endpoint_port', cls._api_server_port), ('VNC', 'cassandra_server_list', "0.0.0.0:9160"), ('VNC', 'cluster_id', cls._cluster_id), ('KUBERNETES', 'service_subnets', "10.96.0.0/12"), ('KUBERNETES', 'ip_fabric_subnets', "10.64.0.0/12"), ('KUBERNETES', 'pod_subnets', "10.32.0.0/12"), ('KUBERNETES', 'cluster_name', cls.cluster_name()), ] kube_config.extend(extra_args) cls._km_greenlet = gevent.spawn( test_common.launch_kube_manager, cls.__name__, kube_config, True, cls.event_queue, cls.vnc_kubernetes_config_dict) test_common.wait_for_kube_manager_up()
def setUpClass(cls, extra_config_knobs=None): extra_config = [ ('DEFAULTS', 'multi_tenancy', 'False'), ('DEFAULTS', 'aaa_mode', 'no-auth'), ] if extra_config_knobs: extra_config.append(extra_config_knobs) super(KMTestCase, cls).setUpClass(extra_config_knobs=extra_config) cls._svc_mon_greenlet = gevent.spawn(test_common.launch_svc_monitor, cls._cluster_id, cls.__name__, cls._api_server_ip, cls._api_server_port) cls._st_greenlet = gevent.spawn(test_common.launch_schema_transformer, cls._cluster_id, cls.__name__, cls._api_server_ip, cls._api_server_port) test_common.wait_for_schema_transformer_up() kube_config = [ ('DEFAULTS', 'log_file', 'contrail-kube-manager.log'), ('VNC', 'vnc_endpoint_ip', cls._api_server_ip), ('VNC', 'vnc_endpoint_port', cls._api_server_port), ('VNC', 'cassandra_server_list', "0.0.0.0:9160"), ('VNC', 'cluster_id', cls._cluster_id), ('KUBERNETES', 'service_subnets', "10.96.0.0/12"), ('KUBERNETES', 'pod_subnets', "10.32.0.0/12"), ('KUBERNETES', 'cluster_name', "test-cluster"), ] cls.event_queue = Queue() cls._km_greenlet = gevent.spawn(test_common.launch_kube_manager, cls.__name__, kube_config, True, cls.event_queue) test_common.wait_for_kube_manager_up()
def spawn_kube_manager(cls): kube_config = [ ('DEFAULTS', 'log_file', 'contrail-kube-manager.log'), ('VNC', 'vnc_endpoint_ip', cls._api_server_ip), ('VNC', 'vnc_endpoint_port', cls._api_server_port), ('VNC', 'cassandra_server_list', "0.0.0.0:9160"), ('VNC', 'cluster_id', cls._cluster_id), ('KUBERNETES', 'service_subnets', "10.96.0.0/12"), ('KUBERNETES', 'pod_subnets', "10.32.0.0/12"), ('KUBERNETES', 'cluster_name', "test-cluster"), ] cls._km_greenlet = gevent.spawn(test_common.launch_kube_manager, cls.__name__, kube_config, True, cls.event_queue) test_common.wait_for_kube_manager_up()
def spawn_kube_manager(cls, extra_args=()): kube_config = [ ('DEFAULTS', 'log_file', 'contrail-kube-manager.log'), ('DEFAULTS', 'logger_class', test_common.ErrorInterceptingLogger.get_qualified_name()), ('VNC', 'vnc_endpoint_ip', cls._api_server_ip), ('VNC', 'vnc_endpoint_port', cls._api_server_port), ('VNC', 'cassandra_server_list', "0.0.0.0:9160"), ('VNC', 'cluster_id', cls._cluster_id), ('VNC', 'kube_timer_interval', '5'), ('KUBERNETES', 'service_subnets', "10.96.0.0/12"), ('KUBERNETES', 'pod_subnets', "10.32.0.0/12"), ('KUBERNETES', 'cluster_name', "test-cluster"), ] kube_config.extend(extra_args) cls._km_greenlet = gevent.spawn(test_common.launch_kube_manager, cls.__name__, kube_config, True, cls.event_queue, cls.vnc_kubernetes_config_dict) test_common.wait_for_kube_manager_up()