brightbox-cli 0.17.1 → 0.17.2
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -1
- data/brightbox-cli.gemspec +10 -9
- data/lib/brightbox-cli/commands/servers-activate-console.rb +1 -1
- data/lib/brightbox-cli/commands/types-show.rb +5 -4
- data/lib/brightbox-cli/config.rb +1 -1
- data/lib/brightbox-cli/detailed_server.rb +2 -1
- data/lib/brightbox-cli/gli_global_hooks.rb +1 -8
- data/lib/brightbox-cli/server_groups.rb +4 -0
- data/lib/brightbox-cli/servers.rb +5 -13
- data/lib/brightbox-cli/types.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/.gitignore +1 -0
- data/lib/brightbox-cli/vendor/fog/README.rdoc +1 -1
- data/lib/brightbox-cli/vendor/fog/Rakefile +4 -3
- data/lib/brightbox-cli/vendor/fog/changelog.txt +213 -0
- data/lib/brightbox-cli/vendor/fog/docs/compute/index.markdown +15 -1
- data/lib/brightbox-cli/vendor/fog/docs/index.markdown +1 -1
- data/lib/brightbox-cli/vendor/fog/docs/storage/index.markdown +4 -4
- data/lib/brightbox-cli/vendor/fog/examples/compute_tests.rb +18 -6
- data/lib/brightbox-cli/vendor/fog/examples/dns_tests.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/examples/storage_tests.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/fog.gemspec +4 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws.rb +16 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/auto_scaling.rb +2 -17
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/cloud_formation.rb +1 -16
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/cloud_watch.rb +2 -17
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/compute.rb +10 -21
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/elasticache.rb +1 -7
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/elb.rb +34 -24
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/emr.rb +5 -4
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/iam.rb +16 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/auto_scaling/group.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/cloud_watch/metric_statistic.rb +1 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/security_group.rb +3 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/security_groups.rb +25 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/server.rb +4 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/dns/records.rb +3 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/elb/listener.rb +9 -7
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/elb/load_balancer.rb +6 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/directory.rb +21 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/file.rb +19 -5
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/files.rb +4 -4
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/compute/describe_instances.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/compute/describe_security_groups.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/sqs/receive_message.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/rds.rb +41 -18
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/create_security_group.rb +6 -4
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/create_tags.rb +3 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/describe_availability_zones.rb +3 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/describe_security_groups.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_app_cookie_stickiness_policy.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_lb_cookie_stickiness_policy.rb +3 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_load_balancer.rb +7 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_load_balancer_listeners.rb +10 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/delete_load_balancer_policy.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/describe_load_balancers.rb +5 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/set_load_balancer_listener_ssl_certificate.rb +27 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/set_load_balancer_policies_of_listener.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/emr/run_job_flow.rb +9 -7
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/add_user_to_group.rb +24 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_access_key.rb +24 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_group.rb +21 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_user.rb +21 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_access_key.rb +17 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_group.rb +19 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_user.rb +17 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_user_policy.rb +16 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_access_keys.rb +21 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_groups.rb +18 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_groups_for_user.rb +24 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_user_policies.rb +18 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_users.rb +17 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/put_user_policy.rb +18 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/remove_user_from_group.rb +19 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/upload_server_certificate.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/authorize_db_security_group_ingress.rb +30 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/create_db_instance.rb +67 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/create_db_security_group.rb +19 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/delete_db_instance.rb +19 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/delete_db_security_group.rb +11 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_instances.rb +56 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_reserved_instances.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_security_groups.rb +44 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/modify_db_instance.rb +26 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/reboot_db_instance.rb +17 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/revoke_db_security_group_ingress.rb +27 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/change_message_visibility.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/delete_message.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/receive_message.rb +13 -14
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/copy_object.rb +14 -6
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/delete_object.rb +73 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket.rb +3 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket_object_versions.rb +95 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket_versioning.rb +32 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object.rb +27 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object_http_url.rb +4 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object_https_url.rb +4 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_bucket_versioning.rb +41 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_bucket_website.rb +17 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_object.rb +25 -9
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/ses.rb +2 -7
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/simpledb.rb +4 -17
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/sns.rb +1 -14
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/sqs.rb +5 -11
- data/lib/brightbox-cli/vendor/fog/lib/fog/aws/storage.rb +6 -22
- data/lib/brightbox-cli/vendor/fog/lib/fog/bin.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/bin/aws.rb +9 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/bin/voxel.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/brightbox/models/compute/server.rb +1 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/compute.rb +6 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/compute/models/server.rb +11 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/core.rb +0 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/core/connection.rb +0 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/core/errors.rb +5 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/core/scp.rb +18 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/core/wait_for.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/dnsmadeeasy/dns.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/dynect/models/dns/records.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/dynect/requests/dns/get_node_list.rb +2 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/compute.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_backup_internet_service.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_internet_service.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_node.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/clone_vapp.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_internet_service.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_network.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_network_ip.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_vapp.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/instantiate_vapp_template.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/compute.rb +7 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/nodes.rb +1 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/server.rb +93 -99
- data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/servers.rb +2 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/util.rb +1 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/providers.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/dns.rb +10 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/load_balancers.rb +3 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/compute/flavor.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/compute/server.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/dns/callback.rb +3 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/dns/record.rb +4 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/load_balancers/load_balancer.rb +18 -8
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/storage/directory.rb +5 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/compute/create_image.rb +1 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/load_balancers/delete_nodes.rb +1 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/load_balancers/list_load_balancers.rb +8 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/storm_on_demand/compute.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/compute.rb +91 -30
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalog.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalog_item.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalogs.rb +5 -8
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/ip.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/network.rb +9 -51
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/networks.rb +21 -7
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/server.rb +38 -58
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/servers.rb +12 -18
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/task.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/tasks.rb +1 -3
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vdc.rb +14 -29
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vdcs.rb +6 -11
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/clone_vapp.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_network.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_network_ip.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_vapp.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_vm.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/instantiate_vapp_template.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/login.rb +8 -4
- data/lib/brightbox-cli/vendor/fog/lib/fog/virtual_box/compute.rb +4 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/compute.rb +1 -0
- data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/models/compute/server.rb +7 -1
- data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/requests/compute/list_virtual_machines.rb +86 -86
- data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/requests/compute/vm_clone.rb +43 -8
- data/lib/brightbox-cli/vendor/fog/lib/fog/zerigo/models/dns/record.rb +7 -5
- data/lib/brightbox-cli/vendor/fog/lib/fog/zerigo/requests/dns/update_host.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/spec/ecloud/spec_helper.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/tests/aws/models/elb/model_tests.rb +15 -6
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/compute/instance_tests.rb +37 -0
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/compute/security_group_tests.rb +6 -4
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/helper.rb +33 -0
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/listener_tests.rb +22 -4
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/policy_tests.rb +13 -0
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/access_key_tests.rb +2 -7
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/group_tests.rb +1 -4
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/user_policy_tests.rb +4 -11
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/user_tests.rb +19 -12
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/rds/helper.rb +38 -3
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/rds/instance_tests.rb +3 -1
- data/lib/brightbox-cli/vendor/fog/tests/aws/requests/storage/bucket_tests.rb +66 -1
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/account_tests.rb +3 -3
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/api_client_tests.rb +6 -6
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/cloud_ip_tests.rb +15 -9
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/helper.rb +6 -2
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/image_tests.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/interface_tests.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/load_balancer_tests.rb +9 -9
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_group_tests.rb +8 -8
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_tests.rb +17 -13
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_type_tests.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/user_tests.rb +3 -3
- data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/zone_tests.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/helper.rb +87 -64
- data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/ip_tests.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/server_tests.rb +4 -4
- data/lib/brightbox-cli/vendor/fog/tests/helpers/formats_helper.rb +1 -1
- data/lib/brightbox-cli/vendor/fog/tests/helpers/mock_helper.rb +2 -0
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/dns/dns_tests.rb +4 -2
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/helper.rb +27 -11
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/load_balancer_tests.rb +4 -1
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/node_tests.rb +24 -25
- data/lib/brightbox-cli/vendor/fog/tests/slicehost/requests/compute/slice_tests.rb +2 -2
- data/lib/brightbox-cli/vendor/fog/tests/storm_on_demand/requests/compute/server_tests.rb +3 -3
- data/lib/brightbox-cli/vendor/fog/tests/vcloud/models/compute/servers_tests.rb +18 -90
- data/lib/brightbox-cli/vendor/fog/tests/vsphere/requests/compute/vm_clone_tests.rb +16 -4
- data/lib/brightbox-cli/vendor/fog/tests/vsphere/requests/compute/vm_power_on_tests.rb +1 -1
- data/lib/brightbox-cli/version.rb +1 -1
- data/spec/cloud_ips_spec.rb +1 -1
- data/spec/fixtures/vcr_cassettes/list_cloud_ip.yml +58 -26
- data/spec/fixtures/vcr_cassettes/server_show.yml +143 -102
- data/spec/servers_spec.rb +3 -2
- data/spec/spec_helper.rb +4 -0
- metadata +128 -213
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/access_list_tests.rb +0 -12
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/access_lists_tests.rb +0 -12
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/load_balancer_tests.rb +0 -116
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/load_balancers_tests.rb +0 -19
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/node_tests.rb +0 -19
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/nodes_tests.rb +0 -12
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/virtual_ip_tests.rb +0 -16
- data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/virtual_ips_tests.rb +0 -12
@@ -27,6 +27,23 @@ module Fog
|
|
27
27
|
end
|
28
28
|
|
29
29
|
end
|
30
|
+
|
31
|
+
class Mock
|
32
|
+
|
33
|
+
def delete_user(user_name)
|
34
|
+
if data[:users].has_key? user_name
|
35
|
+
data[:users].delete user_name
|
36
|
+
Excon::Response.new.tap do |response|
|
37
|
+
response.body = { 'RequestId' => Fog::AWS::Mock.request_id }
|
38
|
+
response.status = 200
|
39
|
+
end
|
40
|
+
else
|
41
|
+
raise Fog::AWS::IAM::NotFound.new("The user with name #{user_name} cannot be found.")
|
42
|
+
end
|
43
|
+
|
44
|
+
end
|
45
|
+
|
46
|
+
end
|
30
47
|
end
|
31
48
|
end
|
32
49
|
end
|
@@ -29,6 +29,22 @@ module Fog
|
|
29
29
|
end
|
30
30
|
|
31
31
|
end
|
32
|
+
|
33
|
+
class Mock
|
34
|
+
|
35
|
+
def delete_user_policy(user_name, policy_name)
|
36
|
+
if data[:users].has_key?(user_name) && data[:users][user_name][:policies].has_key?(policy_name)
|
37
|
+
data[:users][user_name][:policies].delete policy_name
|
38
|
+
Excon::Response.new.tap do |response|
|
39
|
+
response.body = { 'RequestId' => Fog::AWS::Mock.request_id }
|
40
|
+
response.status = 200
|
41
|
+
end
|
42
|
+
else
|
43
|
+
raise Fog::AWS::IAM::NotFound.new("The user policy with name #{policy_name} cannot be found.")
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
end
|
32
48
|
end
|
33
49
|
end
|
34
50
|
end
|
@@ -35,6 +35,27 @@ module Fog
|
|
35
35
|
end
|
36
36
|
|
37
37
|
end
|
38
|
+
|
39
|
+
class Mock
|
40
|
+
|
41
|
+
def list_access_keys(options = {})
|
42
|
+
#FIXME: Doesn't do anything with options, aside from UserName
|
43
|
+
user = options['UserName']
|
44
|
+
|
45
|
+
if data[:users].has_key? user
|
46
|
+
Excon::Response.new.tap do |response|
|
47
|
+
response.body = { 'AccessKeys' => data[:users][user][:access_keys].map do |akey|
|
48
|
+
{'Status' => akey['Status'], 'AccessKeyId' => akey['AccessKeyId']}
|
49
|
+
end,
|
50
|
+
'IsTruncated' => false,
|
51
|
+
'RequestId' => Fog::AWS::Mock.request_id }
|
52
|
+
response.status = 200
|
53
|
+
end
|
54
|
+
else
|
55
|
+
Fog::AWS::IAM::NotFound.new("The user with name #{user} cannot be found.")
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
38
59
|
end
|
39
60
|
end
|
40
61
|
end
|
@@ -37,6 +37,24 @@ module Fog
|
|
37
37
|
end
|
38
38
|
|
39
39
|
end
|
40
|
+
|
41
|
+
class Mock
|
42
|
+
|
43
|
+
def list_groups(options = {} )
|
44
|
+
#FIXME: Doesn't observe options
|
45
|
+
Excon::Response.new.tap do |response|
|
46
|
+
response.status = 200
|
47
|
+
response.body = { 'Groups' => data[:groups].map do |name, group|
|
48
|
+
{ 'GroupId' => group[:group_id],
|
49
|
+
'GroupName' => name,
|
50
|
+
'Path' => group[:path],
|
51
|
+
'Arn' => group[:arn] }
|
52
|
+
end,
|
53
|
+
'IsTruncated' => false,
|
54
|
+
'RequestId' => Fog::AWS::Mock.request_id }
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
40
58
|
end
|
41
59
|
end
|
42
60
|
end
|
@@ -38,6 +38,30 @@ module Fog
|
|
38
38
|
end
|
39
39
|
|
40
40
|
end
|
41
|
+
|
42
|
+
class Mock
|
43
|
+
def list_groups_for_user(user_name, options = {})
|
44
|
+
#FIXME: Does not consider options
|
45
|
+
if data[:users].has_key? user_name
|
46
|
+
Excon::Response.new.tap do |response|
|
47
|
+
response.status = 200
|
48
|
+
response.body = { 'GroupsForUser' => data[:groups].select do |name, group|
|
49
|
+
group[:members].include? user_name
|
50
|
+
end.map do |name, group|
|
51
|
+
{ 'GroupId' => group[:group_id],
|
52
|
+
'GroupName' => name,
|
53
|
+
'Path' => group[:path],
|
54
|
+
'Arn' => group[:arn] }
|
55
|
+
end,
|
56
|
+
'IsTruncated' => false,
|
57
|
+
'RequestId' => Fog::AWS::Mock.request_id
|
58
|
+
}
|
59
|
+
end
|
60
|
+
else
|
61
|
+
raise Fog::AWS::IAM::NotFound.new("The user with name #{user_name} cannot be found.")
|
62
|
+
end
|
63
|
+
end
|
64
|
+
end
|
41
65
|
end
|
42
66
|
end
|
43
67
|
end
|
@@ -34,6 +34,24 @@ module Fog
|
|
34
34
|
end
|
35
35
|
|
36
36
|
end
|
37
|
+
|
38
|
+
class Mock
|
39
|
+
|
40
|
+
def list_user_policies(user_name, options = {})
|
41
|
+
#FIXME: doesn't use options atm
|
42
|
+
if data[:users].has_key? user_name
|
43
|
+
Excon::Response.new.tap do |response|
|
44
|
+
response.body = { 'PolicyNames' => data[:users][user_name][:policies].keys,
|
45
|
+
'IsTruncated' => false,
|
46
|
+
'RequestId' => Fog::AWS::Mock.request_id }
|
47
|
+
response.status = 200
|
48
|
+
end
|
49
|
+
else
|
50
|
+
raise Fog::AWS::IAM::NotFound.new("The user with name #{user_name} cannot be found.")
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
end
|
37
55
|
end
|
38
56
|
end
|
39
57
|
end
|
@@ -37,6 +37,23 @@ module Fog
|
|
37
37
|
end
|
38
38
|
|
39
39
|
end
|
40
|
+
|
41
|
+
class Mock
|
42
|
+
def list_users(options = {})
|
43
|
+
#FIXME: none of the options are currently supported
|
44
|
+
Excon::Response.new.tap do |response|
|
45
|
+
response.body = {'Users' => data[:users].map do |user, data|
|
46
|
+
{ 'UserId' => data[:user_id],
|
47
|
+
'Path' => data[:path],
|
48
|
+
'UserName' => user,
|
49
|
+
'Arn' => data[:arn] }
|
50
|
+
end,
|
51
|
+
'IsTruncated' => false,
|
52
|
+
'RequestId' => Fog::AWS::Mock.request_id }
|
53
|
+
response.status = 200
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
40
57
|
end
|
41
58
|
end
|
42
59
|
end
|
@@ -31,6 +31,24 @@ module Fog
|
|
31
31
|
end
|
32
32
|
|
33
33
|
end
|
34
|
+
|
35
|
+
class Mock
|
36
|
+
|
37
|
+
#FIXME: You can't actually use the credentials for anything elsewhere in Fog
|
38
|
+
#FIXME: Doesn't do any validation on the policy
|
39
|
+
def put_user_policy(user_name, policy_name, policy_document)
|
40
|
+
if data[:users].has_key? user_name
|
41
|
+
data[:users][user_name][:policies][policy_name] = policy_document
|
42
|
+
|
43
|
+
Excon::Response.new.tap do |response|
|
44
|
+
response.body = { 'RequestId' => Fog::AWS::Mock.request_id }
|
45
|
+
response.status = 200
|
46
|
+
end
|
47
|
+
else
|
48
|
+
raise Fog::AWS::IAM::NotFound.new("The user with name #{user_name} cannot be found.")
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
34
52
|
end
|
35
53
|
end
|
36
54
|
end
|
@@ -29,6 +29,25 @@ module Fog
|
|
29
29
|
end
|
30
30
|
|
31
31
|
end
|
32
|
+
|
33
|
+
class Mock
|
34
|
+
|
35
|
+
def remove_user_from_group(group_name, user_name)
|
36
|
+
if data[:groups].has_key? group_name
|
37
|
+
if data[:users].has_key? user_name
|
38
|
+
data[:groups][group_name][:members].delete_if { |item| item == user_name }
|
39
|
+
Excon::Response.new.tap do |response|
|
40
|
+
response.status = 200
|
41
|
+
response.body = { 'RequestId' => Fog::AWS::Mock.request_id }
|
42
|
+
end
|
43
|
+
else
|
44
|
+
raise Fog::AWS::IAM::NotFound.new("The user with name #{user_name} cannot be found.")
|
45
|
+
end
|
46
|
+
else
|
47
|
+
raise Fog::AWS::IAM::NotFound.new("The group with name #{group_name} cannot be found.")
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
32
51
|
end
|
33
52
|
end
|
34
53
|
end
|
@@ -71,7 +71,7 @@ module Fog
|
|
71
71
|
raise Fog::AWS::IAM::EntityAlreadyExists.new
|
72
72
|
else
|
73
73
|
response.status = 200
|
74
|
-
path = options['
|
74
|
+
path = options['Path'] || "/"
|
75
75
|
data = {
|
76
76
|
'Arn' => Fog::AWS::Mock.arn('iam', self.data[:owner_id], "server-certificate/#{name}"),
|
77
77
|
'Path' => path,
|
data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/authorize_db_security_group_ingress.rb
CHANGED
@@ -33,7 +33,36 @@ module Fog
|
|
33
33
|
class Mock
|
34
34
|
|
35
35
|
def authorize_db_security_group_ingress(name, opts = {})
|
36
|
-
|
36
|
+
unless opts.key?('CIDRIP') || (opts.key?('EC2SecurityGroupName') && opts.key?('EC2SecurityGroupOwnerId'))
|
37
|
+
raise ArgumentError, 'Must specify CIDRIP, or both EC2SecurityGroupName and EC2SecurityGroupOwnerId'
|
38
|
+
end
|
39
|
+
|
40
|
+
response = Excon::Response.new
|
41
|
+
|
42
|
+
if sec_group = self.data[:security_groups][name]
|
43
|
+
if opts.key?('CIDRIP')
|
44
|
+
if sec_group['IPRanges'].detect{|h| h['CIDRIP'] == opts['CIDRIP']}
|
45
|
+
raise Fog::AWS::RDS::AuthorizationAlreadyExists.new("AuthorizationAlreadyExists => #{opts['CIDRIP']} is alreay defined")
|
46
|
+
end
|
47
|
+
sec_group['IPRanges'] << opts.merge({"Status" => 'authorizing'})
|
48
|
+
else
|
49
|
+
if sec_group['EC2SecurityGroups'].detect{|h| h['EC2SecurityGroupName'] == opts['EC2SecurityGroupName']}
|
50
|
+
raise Fog::AWS::RDS::AuthorizationAlreadyExists.new("AuthorizationAlreadyExists => #{opts['EC2SecurityGroupName']} is alreay defined")
|
51
|
+
end
|
52
|
+
sec_group['EC2SecurityGroups'] << opts.merge({"Status" => 'authorizing'})
|
53
|
+
end
|
54
|
+
response.status = 200
|
55
|
+
response.body = {
|
56
|
+
"ResponseMetadata"=>{ "RequestId"=> Fog::AWS::Mock.request_id },
|
57
|
+
'AuthorizeDBSecurityGroupIngressResult' => {
|
58
|
+
'DBSecurityGroup' => sec_group
|
59
|
+
}
|
60
|
+
}
|
61
|
+
response
|
62
|
+
else
|
63
|
+
raise Fog::AWS::RDS::NotFound.new("DBSecurityGroupNotFound => #{name} not found")
|
64
|
+
end
|
65
|
+
|
37
66
|
end
|
38
67
|
|
39
68
|
end
|
@@ -47,7 +47,73 @@ module Fog
|
|
47
47
|
class Mock
|
48
48
|
|
49
49
|
def create_db_instance(db_name, options={})
|
50
|
-
|
50
|
+
response = Excon::Response.new
|
51
|
+
if self.data[:servers] and self.data[:servers][db_name]
|
52
|
+
# I don't know how to raise an exception that contains the excon data
|
53
|
+
#response.status = 400
|
54
|
+
#response.body = {
|
55
|
+
# 'Code' => 'DBInstanceAlreadyExists',
|
56
|
+
# 'Message' => "DB Instance already exists"
|
57
|
+
#}
|
58
|
+
#return response
|
59
|
+
raise Fog::AWS::RDS::IdentifierTaken.new("DBInstanceAlreadyExists #{response.body.to_s}")
|
60
|
+
end
|
61
|
+
|
62
|
+
# These are the required parameters according to the API
|
63
|
+
required_params = %w{AllocatedStorage DBInstanceClass Engine MasterUserPassword MasterUsername }
|
64
|
+
required_params.each do |key|
|
65
|
+
unless options.has_key?(key) and options[key] and !options[key].to_s.empty?
|
66
|
+
#response.status = 400
|
67
|
+
#response.body = {
|
68
|
+
# 'Code' => 'MissingParameter',
|
69
|
+
# 'Message' => "The request must contain the parameter #{key}"
|
70
|
+
#}
|
71
|
+
#return response
|
72
|
+
raise Fog::AWS::RDS::NotFound.new("The request must contain the parameter #{key}")
|
73
|
+
end
|
74
|
+
end
|
75
|
+
|
76
|
+
data =
|
77
|
+
{
|
78
|
+
"DBInstanceIdentifier"=> db_name,
|
79
|
+
"DBName" => options["DBName"],
|
80
|
+
"InstanceCreateTime" => nil,
|
81
|
+
"AutoMinorVersionUpgrade"=>true,
|
82
|
+
"Endpoint"=>{},
|
83
|
+
"ReadReplicaDBInstanceIdentifiers"=>['bla'],
|
84
|
+
"PreferredMaintenanceWindow"=>"mon:04:30-mon:05:00",
|
85
|
+
"Engine"=> options["Engine"],
|
86
|
+
"EngineVersion"=> options["EngineVersion"] || "5.1.57",
|
87
|
+
"PendingModifiedValues"=>{"MasterUserPassword"=>"****"}, # This clears when is available
|
88
|
+
"MultiAZ"=>false,
|
89
|
+
"MasterUsername"=> options["MasterUsername"],
|
90
|
+
"DBInstanceClass"=> options["DBInstanceClass"],
|
91
|
+
"DBInstanceStatus"=>"creating",
|
92
|
+
"BackupRetentionPeriod"=> options["BackupRetentionPeriod"] || 1,
|
93
|
+
"AllocatedStorage"=> options["AllocatedStorage"],
|
94
|
+
"DBParameterGroups"=> # I think groups should be in the self.data method
|
95
|
+
[{"DBParameterGroupName"=>"default.mysql5.1",
|
96
|
+
"ParameterApplyStatus"=>"in-sync"}],
|
97
|
+
"DBSecurityGroups"=>
|
98
|
+
[{"Status"=>"active",
|
99
|
+
"DBSecurityGroupName"=>"default"}],
|
100
|
+
"LicenseModel"=>"general-public-license",
|
101
|
+
"PreferredBackupWindow"=>"08:00-08:30",
|
102
|
+
# "ReadReplicaSourceDBInstanceIdentifier" => nil,
|
103
|
+
# "LatestRestorableTime" => nil,
|
104
|
+
"AvailabilityZone" => options["AvailabilityZone"]
|
105
|
+
}
|
106
|
+
|
107
|
+
|
108
|
+
self.data[:servers][db_name] = data
|
109
|
+
response.body = {
|
110
|
+
"ResponseMetadata"=>{ "RequestId"=> Fog::AWS::Mock.request_id },
|
111
|
+
"CreateDBInstanceResult"=> {"DBInstance"=> data}
|
112
|
+
}
|
113
|
+
response.status = 200
|
114
|
+
# This values aren't showed at creating time but at available time
|
115
|
+
self.data[:servers][db_name]["InstanceCreateTime"] = Time.now
|
116
|
+
response
|
51
117
|
end
|
52
118
|
|
53
119
|
end
|
@@ -27,7 +27,25 @@ module Fog
|
|
27
27
|
class Mock
|
28
28
|
|
29
29
|
def create_db_security_group(name, description = name)
|
30
|
-
|
30
|
+
response = Excon::Response.new
|
31
|
+
if self.data[:security_groups] and self.data[:security_groups][name]
|
32
|
+
raise Fog::AWS::RDS::IdentifierTaken.new("DBInstanceAlreadyExists => The security group '#{name}' already exists")
|
33
|
+
end
|
34
|
+
|
35
|
+
data = {
|
36
|
+
'DBSecurityGroupName' => name,
|
37
|
+
'DBSecurityGroupDescription' => description,
|
38
|
+
'EC2SecurityGroups' => [],
|
39
|
+
'IPRanges' => [],
|
40
|
+
'OwnerId' => '0123456789'
|
41
|
+
}
|
42
|
+
self.data[:security_groups][name] = data
|
43
|
+
response.body = {
|
44
|
+
"ResponseMetadata"=>{ "RequestId"=> Fog::AWS::Mock.request_id },
|
45
|
+
'CreateDBSecurityGroupResult' => { 'DBSecurityGroup' => data }
|
46
|
+
}
|
47
|
+
response
|
48
|
+
|
31
49
|
end
|
32
50
|
|
33
51
|
end
|
@@ -15,7 +15,7 @@ module Fog
|
|
15
15
|
# ==== Returns
|
16
16
|
# * response<~Excon::Response>:
|
17
17
|
# * body<~Hash>:
|
18
|
-
def delete_db_instance(identifier, snapshot_identifier, skip_snapshot = false)
|
18
|
+
def delete_db_instance(identifier, snapshot_identifier, skip_snapshot = false)
|
19
19
|
params = {}
|
20
20
|
params['FinalDBSnapshotIdentifier'] = snapshot_identifier if snapshot_identifier
|
21
21
|
request({
|
@@ -30,8 +30,24 @@ module Fog
|
|
30
30
|
|
31
31
|
class Mock
|
32
32
|
|
33
|
-
def
|
34
|
-
|
33
|
+
def delete_db_instance(identifier, snapshot_identifier, skip_snapshot = false)
|
34
|
+
response = Excon::Response.new
|
35
|
+
|
36
|
+
unless skip_snapshot
|
37
|
+
# I don't know how to mock snapshot_identifier
|
38
|
+
Fog::Logger.warning("snapshot_identifier is not mocked [light_black](#{caller.first})[/]")
|
39
|
+
end
|
40
|
+
|
41
|
+
if server_set = self.data[:servers].delete(identifier)
|
42
|
+
response.status = 200
|
43
|
+
response.body = {
|
44
|
+
"ResponseMetadata"=>{ "RequestId"=> Fog::AWS::Mock.request_id },
|
45
|
+
"DeleteDBInstanceResult" => { "DBInstance" => server_set }
|
46
|
+
}
|
47
|
+
response
|
48
|
+
else
|
49
|
+
raise Fog::AWS::RDS::NotFound.new("DBInstance #{identifier} not found")
|
50
|
+
end
|
35
51
|
end
|
36
52
|
|
37
53
|
end
|
@@ -25,7 +25,17 @@ module Fog
|
|
25
25
|
class Mock
|
26
26
|
|
27
27
|
def delete_db_security_group(name, description = name)
|
28
|
-
|
28
|
+
response = Excon::Response.new
|
29
|
+
|
30
|
+
if self.data[:security_groups].delete(name)
|
31
|
+
response.status = 200
|
32
|
+
response.body = {
|
33
|
+
"ResponseMetadata"=>{ "RequestId"=> Fog::AWS::Mock.request_id },
|
34
|
+
}
|
35
|
+
response
|
36
|
+
else
|
37
|
+
raise Fog::AWS::RDS::NotFound.new("DBSecurityGroupNotFound => #{name} not found")
|
38
|
+
end
|
29
39
|
end
|
30
40
|
|
31
41
|
end
|