ansible/ansible — pull request #5918 by spectrumx (2014-02-09 01:37:00+00:00)
Title: Added support for multiple VPCs in ec2_vpc module

Added support for multiple VPCs in the same AWS region that use the same CIDR blocks - provided tags are used to uniquely name/identify a VPC resource. For example, we have a number of "environments" or "stacks" that are almost identical in structure such as Development V x.x , System Integration Test, DevOps, Demo, etc. - they all use the same network definition, IP address ranges, etc to make things easier to configure.

code has been rebased from devel branch
make tests been run without failures:

➜ ansible git:(devel) make tests
PYTHONPATH=./lib ANSIBLE_LIBRARY=./library nosetests -d -v
test_callback (TestCallback.TestInventory) ... ok
test_callback_disabled (TestCallback.TestInventory) ... ok
test_configfile_and_env_both_set (TestConstants.TestConstants) ... ok
test_configfile_not_set_env_not_set (TestConstants.TestConstants) ... ok
test_configfile_not_set_env_set (TestConstants.TestConstants) ... ok
test_configfile_set_env_not_set (TestConstants.TestConstants) ... ok
test_bool_no (TestFilters.TestFilters) ... ok
test_bool_none (TestFilters.TestFilters) ... ok
test_bool_true (TestFilters.TestFilters) ... ok
test_bool_yes (TestFilters.TestFilters) ... ok
test_fileglob (TestFilters.TestFilters) ... ok
test_match_case_insensitive (TestFilters.TestFilters) ... ok
test_match_case_sensitive (TestFilters.TestFilters) ... ok
test_match_no_match (TestFilters.TestFilters) ... ok
test_quotes (TestFilters.TestFilters) ... ok
test_regex (TestFilters.TestFilters) ... ok
test_search_case_insensitive (TestFilters.TestFilters) ... ok
test_search_case_sensitive (TestFilters.TestFilters) ... ok
test_alpha_end_before_beg (TestInventory.TestInventory) ... ok
test_combined_range (TestInventory.TestInventory) ... ok
test_complex_enumeration (TestInventory.TestInventory) ... ok
test_complex_exclude (TestInventory.TestInventory) ... ok
test_complex_group_names (TestInventory.TestInventory) ... ok
test_complex_intersect (TestInventory.TestInventory) ... ok
test_complex_vars (TestInventory.TestInventory) ... ok
test_empty (TestInventory.TestInventory) ... ok
test_get_hosts (TestInventory.TestInventory) ... ok
test_hosts_list (TestInventory.TestInventory) ... ok
test_incorrect_format (TestInventory.TestInventory) ... ok
test_invalid_range (TestInventory.TestInventory) ... ok
test_large_range (TestInventory.TestInventory) ... ok
test_leading_range (TestInventory.TestInventory) ... ok
test_missing_end (TestInventory.TestInventory) ... ok
test_no_src (TestInventory.TestInventory) ... ok
test_regex_exclude (TestInventory.TestInventory) ... ok
test_script (TestInventory.TestInventory) ... ok
test_script_all (TestInventory.TestInventory) ... ok
test_script_combined (TestInventory.TestInventory) ... ok
test_script_multiple_groups (TestInventory.TestInventory) ... ok
test_script_norse (TestInventory.TestInventory) ... ok
test_script_restrict (TestInventory.TestInventory) ... ok
test_script_vars (TestInventory.TestInventory) ... ok
test_simple (TestInventory.TestInventory) ... ok
test_simple_all (TestInventory.TestInventory) ... ok
test_simple_combined (TestInventory.TestInventory) ... ok
test_simple_norse (TestInventory.TestInventory) ... ok
test_simple_port (TestInventory.TestInventory) ... ok
test_simple_restrict (TestInventory.TestInventory) ... ok
test_simple_string_fqdn (TestInventory.TestInventory) ... ok
test_simple_string_fqdn_port (TestInventory.TestInventory) ... ok
test_simple_string_fqdn_vars (TestInventory.TestInventory) ... ok
test_simple_string_ipv4 (TestInventory.TestInventory) ... ok
test_simple_string_ipv4_port (TestInventory.TestInventory) ... ok
test_simple_string_ipv4_vars (TestInventory.TestInventory) ... ok
test_simple_string_ipv6 (TestInventory.TestInventory) ... ok
test_simple_string_ipv6_port (TestInventory.TestInventory) ... ok
test_simple_string_ipv6_vars (TestInventory.TestInventory) ... ok
test_simple_ungrouped (TestInventory.TestInventory) ... ok
test_simple_vars (TestInventory.TestInventory) ... ok
test_subset (TestInventory.TestInventory) ... ok
test_subset_filename (TestInventory.TestInventory) ... ok
testinvalid_entry (TestInventory.TestInventory) ... ok
test_playbook_always_run (TestPlayBook.TestPlaybook) ... ok
test_playbook_changed_when (TestPlayBook.TestPlaybook) ... ok
test_playbook_failed_when (TestPlayBook.TestPlaybook) ... ok
test_playbook_hash_merge (TestPlayBook.TestPlaybook) ... ok
test_playbook_hash_replace (TestPlayBook.TestPlaybook) ... ok
test_playbook_ignore_errors (TestPlayBook.TestPlaybook) ... ok
test_playbook_vars (TestPlayBook.TestPlaybook) ... ok
test_recursive_copy (TestPlayBook.TestPlaybook) ... ok
test_yaml_hosts_list (TestPlayBook.TestPlaybook) ... ok
test_action_plugins (TestRunner.TestRunner) ... ok
test_assemble (TestRunner.TestRunner) ... ok
test_async (TestRunner.TestRunner) ... ok
test_command (TestRunner.TestRunner) ... ok
test_copy (TestRunner.TestRunner) ... ok
test_facter (TestRunner.TestRunner) ... SKIP
test_fetch (TestRunner.TestRunner) ... ok
test_file (TestRunner.TestRunner) ... ok
test_git (TestRunner.TestRunner) ... ok
test_large_output (TestRunner.TestRunner) ... ok
test_lineinfile (TestRunner.TestRunner) ... ok
test_lineinfile_backrefs (TestRunner.TestRunner) ... ok
test_ping (TestRunner.TestRunner) ... ok
test_check_conditional_jinja2_expression (TestUtils.TestUtils) ... ok
test_check_conditional_jinja2_expression_in_variable (TestUtils.TestUtils) ... ok
test_check_conditional_jinja2_literals (TestUtils.TestUtils) ... ok
test_check_conditional_jinja2_unicode (TestUtils.TestUtils) ... ok
test_check_conditional_jinja2_variable_literals (TestUtils.TestUtils) ... ok
test_loaders_expanduser_each_dir (TestUtils.TestUtils) ... ok
test_parse_kv_basic (TestUtils.TestUtils) ... ok
test_template_basic (TestUtils.TestUtils) ... ok
test_template_ds_basic (TestUtils.TestUtils) ... ok
test_template_unicode (TestUtils.TestUtils) ... ok
test_template_whitespace (TestUtils.TestUtils) ... ok
test_varReplace_var_complex_var (TestUtils.TestUtils) ... ok

----------------------------------------------------------------------
Ran 96 tests in 31.742s

OK (SKIP=1)