Module Import alias Import alias Import alias ImportFrom alias Import alias Import alias Import alias Import alias Assign NameStore Str Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Import alias identifier Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Str Assign NameStore ListLoad Str Str Str FunctionDef arguments args defaults body For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args defaults body Expr Str TryFinally body Assign NameStore Call AttributeLoad NameLoad attr Dict Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return NameLoad finalbody Expr Call NameLoad decorator_list ClassDef bases AttributeLoad NameLoad attr body Assign NameStore NameLoad Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore SubscriptLoad SubscriptLoad AttributeLoad NameLoad attr Index Str Index Str Expr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Str Assign NameStore SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body For NameStore AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad Expr Call AttributeLoad NameLoad attr NameLoad BinOpMod Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad If CompareNotEq NameLoad Str body Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore ListLoad Str Str Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore Call NameLoad Num Num body Assign NameStore Call NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Str For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad NameLoad Index Str For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body If CompareIn Str Call AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad NameLoad Index Str AugAssignAdd SubscriptStore NameLoad Index NameLoad Num Expr Call AttributeLoad NameLoad attr Num SubscriptLoad NameLoad Index NameLoad keyword BinOpMod Str NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr ListLoad decorator_list decorator_list ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad AttributeLoad NameLoad attr attr BoolOpOr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Dict decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body TryFinally body If CompareIn NameLoad NameLoad body Delete SubscriptDel NameLoad Index NameLoad orelse If CompareIn NameLoad SubscriptLoad NameLoad Index Str body Delete SubscriptDel SubscriptLoad NameLoad Index Str Index NameLoad orelse Raise Call NameLoad Str finalbody Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Delete SubscriptDel SubscriptLoad AttributeLoad NameLoad attr Index Str Index NameLoad Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr NameLoad BinOpAdd NameLoad Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr Str With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr Str With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Delete SubscriptDel AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad NameLoad attr With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr CompareIn NameLoad AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str With Call AttributeLoad NameLoad attr NameLoad NameStore body Expr Call NameLoad Assign NameStore Str Expr Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr BinOpAdd NameLoad Str NameLoad decorator_list decorator_list If CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr
N/A N/A collections N/A json N/A os os path N/A Queue N/A sys N/A unittest N/A yaml N/A INV_DIR playbooks/inventory N/A SCRIPT_FILENAME dynamic_inventory.py N/A INV_SCRIPT N/A N/A path join N/A N/A os getcwd INV_DIR SCRIPT_FILENAME N/A N/A N/A N/A sys path append N/A N/A path join N/A N/A os getcwd INV_DIR N/A dynamic_inventory di N/A TARGET_DIR N/A N/A path join N/A N/A os getcwd tests inventory N/A USER_CONFIG_FILE N/A N/A path join TARGET_DIR openstack_user_config.yml N/A CLEANUP N/A openstack_inventory.json openstack_hostnames_ips.yml backup_openstack_inventory.tar cleanup N/A N/A N/A N/A N/A f_name CLEANUP N/A N/A f_file N/A N/A path join TARGET_DIR f_name N/A N/A N/A N/A os path exists f_file N/A N/A N/A N/A os remove f_file N/A get_inventory N/A N/A N/A N/A N/A Return the inventory mapping in a dict. N/A N/A N/A inventory_string N/A N/A di main N/A config TARGET_DIR N/A inventory N/A N/A json loads inventory_string N/A inventory N/A N/A N/A cleanup N/A TestAnsibleInventoryFormatConstraints N/A N/A unittest TestCase N/A N/A inventory None N/A expected_groups N/A aio1_containers all all_containers aodh_alarm_evaluator aodh_alarm_notifier aodh_all aodh_api aodh_container aodh_listener ceilometer_agent_central ceilometer_agent_compute ceilometer_agent_notification ceilometer_all ceilometer_api ceilometer_api_container ceilometer_collector ceilometer_collector_container cinder_all cinder_api cinder_api_container cinder_backup cinder_scheduler cinder_scheduler_container cinder_volume cinder_volumes_container compute_all compute_containers compute_hosts galera galera_all galera_container glance_all glance_api glance_container glance_registry haproxy haproxy_all haproxy_container haproxy_containers haproxy_hosts heat_all heat_api heat_api_cfn heat_api_cloudwatch heat_apis_container heat_engine heat_engine_container horizon horizon_all horizon_container hosts identity_all identity_containers identity_hosts infra_containers infra_hosts ironic-server_hosts ironic_conductor_container ironic_api_container ironic_conductor ironic-infra_containers ironic-infra_hosts ironic_servers ironic-server_containers ironic_all ironic_server ironic_server_container ironic_api keystone keystone_all keystone_container log_all log_containers log_hosts memcached memcached_all memcached_container metering-alarm_containers metering-alarm_hosts metering-compute_container metering-compute_containers metering-compute_hosts metering-infra_containers metering-infra_hosts network_all network_containers network_hosts neutron_agent neutron_agents_container neutron_all neutron_dhcp_agent neutron_l3_agent neutron_lbaas_agent neutron_linuxbridge_agent neutron_metadata_agent neutron_metering_agent neutron_server neutron_server_container nova_all nova_api_metadata nova_api_metadata_container nova_api_os_compute nova_api_os_compute_container nova_cert nova_cert_container nova_compute nova_compute_container nova_conductor nova_conductor_container nova_console nova_console_container nova_scheduler nova_scheduler_container os-infra_all os-infra_containers os-infra_hosts pkg_repo rabbit_mq_container rabbitmq rabbitmq_all remote remote_containers repo-infra_all repo-infra_containers repo-infra_hosts repo_all repo_container rsyslog rsyslog_all rsyslog_container shared-infra_all shared-infra_containers shared-infra_hosts storage-infra_all storage-infra_containers storage-infra_hosts storage_all storage_containers storage_hosts swift-proxy_containers swift-proxy_hosts swift-remote_containers swift-remote_hosts swift_acc swift_acc_container swift_all swift_cont swift_cont_container swift_containers swift_hosts swift_obj swift_obj_container swift_proxy swift_proxy_container swift_remote swift_remote_all swift_remote_container utility utility_all utility_container setUpClass N/A N/A cls N/A N/A N/A N/A cls inventory N/A get_inventory N/A classmethod test_meta N/A N/A self N/A N/A N/A meta N/A N/A self inventory N/A _meta N/A N/A N/A self assertIsNotNone meta _meta missing from inventory N/A N/A N/A self assertIsInstance meta dict _meta is not a dict N/A test_hostvars N/A N/A self N/A N/A N/A hostvars N/A N/A N/A self inventory N/A _meta N/A hostvars N/A N/A N/A self assertIsNotNone hostvars hostvars missing from _meta N/A N/A N/A self assertIsInstance hostvars dict hostvars is not a dict N/A test_group_vars_all N/A N/A self N/A N/A N/A group_vars_all N/A N/A self inventory N/A all N/A N/A N/A self assertIsNotNone group_vars_all group vars all missing from inventory N/A N/A N/A self assertIsInstance group_vars_all dict group vars all is not a dict N/A the_vars N/A group_vars_all N/A vars N/A N/A N/A self assertIsNotNone the_vars vars missing from group vars all N/A N/A N/A self assertIsInstance the_vars dict vars in group vars all is not a dict N/A test_expected_host_groups_present N/A N/A self N/A N/A N/A group N/A self expected_groups N/A N/A the_group N/A N/A self inventory N/A group N/A N/A N/A self assertIsNotNone the_group N/A Required host group: %s is missing from inventory group N/A N/A N/A self assertIsInstance the_group dict N/A N/A group all N/A N/A N/A N/A self assertIn hosts the_group N/A N/A N/A self assertIsInstance N/A the_group N/A hosts list N/A test_only_expected_host_groups_present N/A N/A self N/A N/A N/A all_keys N/A list N/A self expected_groups N/A N/A N/A all_keys append _meta N/A N/A N/A self assertEqual N/A set all_keys N/A set N/A N/A N/A self inventory keys N/A N/A TestUserConfiguration N/A N/A unittest TestCase N/A setUp N/A N/A self N/A N/A N/A N/A self longMessage True N/A N/A self loaded_user_configuration N/A N/A di load_user_configuration TARGET_DIR N/A test_loading_user_configuration N/A N/A self N/A N/A N/A Test that the user configuration can be loaded N/A N/A N/A self assertIsInstance N/A self loaded_user_configuration dict N/A N/A TestEnvironments N/A N/A unittest TestCase N/A setUp N/A N/A self N/A N/A N/A N/A self longMessage True N/A N/A self loaded_environment N/A N/A di load_environment TARGET_DIR N/A test_loading_environment N/A N/A self N/A N/A N/A Test that the environment can be loaded N/A N/A N/A self assertIsInstance N/A self loaded_environment dict N/A test_envd_read N/A N/A self N/A N/A N/A Test that the env.d contents are inserted into the environment N/A expected_keys N/A component_skel container_skel physical_skel N/A key expected_keys N/A N/A N/A N/A self assertIn key N/A self loaded_environment N/A N/A TestIps N/A N/A unittest TestCase N/A setUp N/A N/A self N/A N/A N/A N/A self longMessage True N/A test_duplicates N/A N/A self N/A N/A N/A Test that no duplicate IPs are made on any network. N/A i N/A xrange 0 99 N/A N/A inventory N/A get_inventory N/A ips N/A N/A collections defaultdict int N/A hostvars N/A N/A inventory N/A _meta N/A hostvars N/A N/A host var_dict N/A N/A hostvars items N/A N/A nets N/A var_dict N/A container_networks N/A N/A net vals N/A N/A nets items N/A N/A N/A address N/A N/A vals keys N/A N/A addr N/A vals N/A address N/A N/A ips N/A addr 1 N/A N/A N/A self assertEqual 1 N/A ips N/A addr msg N/A IP %s duplicated. addr N/A test_empty_ip_queue N/A N/A self N/A N/A N/A q N/A N/A Queue Queue N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A N/A di get_ip_address test q N/A expectedLog Cannot retrieve requested amount of IP addresses. Increase the test range in your openstack_user_config.yml. N/A N/A N/A self assertEqual N/A N/A context exception message expectedLog N/A tearDown N/A N/A self N/A N/A N/A N/A di USED_IPS N/A N/A N/A TestConfigChecks N/A N/A unittest TestCase N/A setUp N/A N/A self N/A N/A N/A N/A self user_defined_config N/A dict N/A N/A open USER_CONFIG_FILE rb f N/A N/A N/A N/A N/A self user_defined_config update N/A N/A N/A yaml safe_load N/A N/A f read N/A N/A delete_config_key N/A N/A self user_defined_config key N/A N/A N/A N/A N/A N/A key user_defined_config N/A N/A N/A user_defined_config N/A key N/A N/A N/A key N/A user_defined_config N/A global_overrides N/A N/A N/A N/A user_defined_config N/A global_overrides N/A key N/A N/A N/A KeyError can't find specified key in user config N/A N/A N/A N/A self write_config N/A delete_provider_network N/A N/A self net_name N/A N/A N/A N/A N/A N/A self user_defined_config N/A cidr_networks N/A net_name N/A N/A N/A self write_config N/A write_config N/A N/A self N/A N/A N/A N/A N/A os rename USER_CONFIG_FILE N/A USER_CONFIG_FILE .tmp N/A N/A open USER_CONFIG_FILE wb f N/A N/A N/A N/A f write N/A N/A yaml dump N/A self user_defined_config N/A test_missing_container_cidr_network N/A N/A self N/A N/A N/A N/A N/A self delete_provider_network container N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A get_inventory N/A expectedLog No container or management network specified in user config. N/A N/A N/A self assertEqual N/A N/A context exception message expectedLog N/A test_missing_cidr_network_present_in_provider N/A N/A self N/A N/A N/A N/A N/A self delete_provider_network storage N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A get_inventory N/A expectedLog can't find storage in cidr_networks N/A N/A N/A self assertEqual N/A N/A context exception message expectedLog N/A test_missing_cidr_networks_key N/A N/A self N/A N/A N/A N/A N/A self user_defined_config N/A cidr_networks N/A N/A N/A self write_config N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A get_inventory N/A expectedLog No container CIDR specified in user config N/A N/A N/A self assertEqual N/A N/A context exception message expectedLog N/A test_provider_networks_check N/A N/A self N/A N/A N/A N/A N/A self delete_config_key N/A self user_defined_config provider_networks N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A get_inventory N/A expectedLog provider networks can't be found under global_overrides N/A N/A N/A self assertTrue N/A expectedLog N/A N/A context exception message N/A test_global_overrides_check N/A N/A self N/A N/A N/A N/A N/A self delete_config_key N/A self user_defined_config global_overrides N/A N/A N/A self assertRaises SystemExit context N/A N/A N/A get_inventory N/A expectedLog global_overrides can't be found in user config N/A N/A N/A self assertEqual N/A N/A context exception message expectedLog N/A tearDown N/A N/A self N/A N/A N/A N/A N/A os remove USER_CONFIG_FILE N/A N/A N/A os rename N/A USER_CONFIG_FILE .tmp USER_CONFIG_FILE N/A N/A N/A N/A __name__ __main__ N/A N/A N/A N/A unittest main