fog 1.7.0 → 1.8.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +2 -2
- data/README.md +9 -10
- data/Rakefile +15 -299
- data/changelog.txt +153 -0
- data/docs/about/contributing.markdown +1 -0
- data/docs/dns/index.markdown +1 -1
- data/docs/index.markdown +8 -3
- data/fog.gemspec +3 -3
- data/lib/fog.rb +0 -5
- data/lib/fog/aws/auto_scaling.rb +1 -1
- data/lib/fog/aws/cloud_watch.rb +1 -1
- data/lib/fog/aws/compute.rb +2 -1
- data/lib/fog/aws/dynamodb.rb +30 -64
- data/lib/fog/aws/elb.rb +1 -1
- data/lib/fog/aws/glacier.rb +1 -1
- data/lib/fog/aws/iam.rb +1 -0
- data/lib/fog/aws/models/auto_scaling/group.rb +1 -1
- data/lib/fog/aws/models/compute/server.rb +2 -0
- data/lib/fog/aws/models/compute/volume.rb +0 -1
- data/lib/fog/aws/models/iam/user.rb +1 -1
- data/lib/fog/aws/parsers/compute/describe_instances.rb +3 -1
- data/lib/fog/aws/parsers/compute/describe_reserved_instances_offerings.rb +1 -1
- data/lib/fog/aws/parsers/storage/delete_multiple_objects.rb +50 -0
- data/lib/fog/aws/rds.rb +2 -2
- data/lib/fog/aws/requests/compute/describe_availability_zones.rb +3 -0
- data/lib/fog/aws/requests/compute/describe_reserved_instances_offerings.rb +11 -8
- data/lib/fog/aws/requests/compute/modify_volume_attribute.rb +51 -0
- data/lib/fog/aws/requests/dns/change_resource_record_sets.rb +1 -0
- data/lib/fog/aws/requests/storage/delete_multiple_objects.rb +172 -0
- data/lib/fog/aws/signaturev4.rb +1 -1
- data/lib/fog/aws/sqs.rb +1 -1
- data/lib/fog/aws/storage.rb +2 -0
- data/lib/fog/bluebox/requests/compute/create_block.rb +1 -3
- data/lib/fog/brightbox/compute.rb +239 -84
- data/lib/fog/brightbox/models/compute/account.rb +9 -3
- data/lib/fog/brightbox/models/compute/server.rb +2 -1
- data/lib/fog/brightbox/models/compute/servers.rb +33 -1
- data/lib/fog/brightbox/oauth2.rb +164 -0
- data/lib/fog/brightbox/requests/compute/activate_console_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/add_listeners_load_balancer.rb +11 -2
- data/lib/fog/brightbox/requests/compute/add_nodes_load_balancer.rb +11 -2
- data/lib/fog/brightbox/requests/compute/add_servers_server_group.rb +9 -11
- data/lib/fog/brightbox/requests/compute/apply_to_firewall_policy.rb +11 -2
- data/lib/fog/brightbox/requests/compute/create_api_client.rb +11 -2
- data/lib/fog/brightbox/requests/compute/create_application.rb +11 -2
- data/lib/fog/brightbox/requests/compute/create_cloud_ip.rb +11 -1
- data/lib/fog/brightbox/requests/compute/create_firewall_policy.rb +13 -2
- data/lib/fog/brightbox/requests/compute/create_firewall_rule.rb +17 -2
- data/lib/fog/brightbox/requests/compute/create_image.rb +18 -2
- data/lib/fog/brightbox/requests/compute/create_load_balancer.rb +14 -2
- data/lib/fog/brightbox/requests/compute/create_server.rb +17 -2
- data/lib/fog/brightbox/requests/compute/create_server_group.rb +11 -2
- data/lib/fog/brightbox/requests/compute/destroy_api_client.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_application.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_cloud_ip.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_firewall_policy.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_firewall_rule.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_image.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_load_balancer.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/destroy_server_group.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_account.rb +7 -15
- data/lib/fog/brightbox/requests/compute/get_api_client.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_application.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_authenticated_user.rb +1 -3
- data/lib/fog/brightbox/requests/compute/get_cloud_ip.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_firewall_policy.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_firewall_rule.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_image.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_interface.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_load_balancer.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_scoped_account.rb +1 -5
- data/lib/fog/brightbox/requests/compute/get_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_server_group.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_server_type.rb +9 -2
- data/lib/fog/brightbox/requests/compute/get_user.rb +7 -15
- data/lib/fog/brightbox/requests/compute/get_zone.rb +9 -2
- data/lib/fog/brightbox/requests/compute/list_accounts.rb +6 -2
- data/lib/fog/brightbox/requests/compute/list_api_clients.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_applications.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_cloud_ips.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_firewall_policies.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_images.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_load_balancers.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_server_groups.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_server_types.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_servers.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_users.rb +8 -2
- data/lib/fog/brightbox/requests/compute/list_zones.rb +8 -2
- data/lib/fog/brightbox/requests/compute/map_cloud_ip.rb +11 -2
- data/lib/fog/brightbox/requests/compute/move_servers_server_group.rb +10 -12
- data/lib/fog/brightbox/requests/compute/remove_firewall_policy.rb +11 -2
- data/lib/fog/brightbox/requests/compute/remove_listeners_load_balancer.rb +11 -2
- data/lib/fog/brightbox/requests/compute/remove_nodes_load_balancer.rb +11 -2
- data/lib/fog/brightbox/requests/compute/remove_servers_server_group.rb +9 -10
- data/lib/fog/brightbox/requests/compute/reset_ftp_password_account.rb +22 -3
- data/lib/fog/brightbox/requests/compute/reset_ftp_password_scoped_account.rb +18 -0
- data/lib/fog/brightbox/requests/compute/reset_secret_api_client.rb +13 -1
- data/lib/fog/brightbox/requests/compute/reset_secret_application.rb +9 -2
- data/lib/fog/brightbox/requests/compute/shutdown_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/snapshot_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/start_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/stop_server.rb +9 -2
- data/lib/fog/brightbox/requests/compute/unmap_cloud_ip.rb +9 -2
- data/lib/fog/brightbox/requests/compute/update_account.rb +32 -34
- data/lib/fog/brightbox/requests/compute/update_api_client.rb +12 -2
- data/lib/fog/brightbox/requests/compute/update_application.rb +12 -2
- data/lib/fog/brightbox/requests/compute/update_cloud_ip.rb +13 -2
- data/lib/fog/brightbox/requests/compute/update_firewall_rule.rb +16 -1
- data/lib/fog/brightbox/requests/compute/update_image.rb +17 -2
- data/lib/fog/brightbox/requests/compute/update_load_balancer.rb +15 -2
- data/lib/fog/brightbox/requests/compute/update_scoped_account.rb +12 -19
- data/lib/fog/brightbox/requests/compute/update_server.rb +12 -2
- data/lib/fog/brightbox/requests/compute/update_server_group.rb +12 -2
- data/lib/fog/brightbox/requests/compute/update_user.rb +15 -2
- data/lib/fog/cloudstack/models/compute/server.rb +3 -1
- data/lib/fog/core.rb +1 -0
- data/lib/fog/core/connection.rb +1 -0
- data/lib/fog/google/storage.rb +13 -2
- data/lib/fog/libvirt/models/compute/server.rb +1 -0
- data/lib/fog/libvirt/requests/compute/list_domains.rb +2 -2
- data/lib/fog/openstack.rb +57 -58
- data/lib/fog/openstack/compute.rb +15 -14
- data/lib/fog/openstack/identity.rb +10 -2
- data/lib/fog/openstack/image.rb +1 -1
- data/lib/fog/openstack/models/compute/flavor.rb +5 -1
- data/lib/fog/openstack/models/compute/security_group.rb +1 -1
- data/lib/fog/openstack/models/compute/server.rb +5 -0
- data/lib/fog/openstack/models/identity/users.rb +1 -2
- data/lib/fog/openstack/requests/compute/create_flavor.rb +4 -1
- data/lib/fog/openstack/requests/compute/create_security_group.rb +1 -1
- data/lib/fog/openstack/requests/compute/get_limits.rb +93 -0
- data/lib/fog/openstack/requests/compute/list_tenants.rb +1 -0
- data/lib/fog/openstack/requests/compute/release_address.rb +13 -1
- data/lib/fog/openstack/requests/compute/reset_server_state.rb +24 -0
- data/lib/fog/openstack/requests/identity/create_role.rb +1 -1
- data/lib/fog/openstack/requests/identity/set_tenant.rb +21 -0
- data/lib/fog/openstack/volume.rb +2 -1
- data/lib/fog/rackspace/models/compute_v2/server.rb +27 -0
- data/lib/fog/rackspace/models/compute_v2/servers.rb +8 -0
- data/lib/fog/rackspace/models/dns/record.rb +14 -1
- data/lib/fog/rackspace/models/storage/file.rb +68 -2
- data/lib/fog/rackspace/requests/compute_v2/create_server.rb +3 -0
- data/lib/fog/version.rb +5 -0
- data/lib/fog/vsphere/compute.rb +74 -8
- data/lib/fog/vsphere/models/compute/cluster.rb +31 -0
- data/lib/fog/vsphere/models/compute/clusters.rb +26 -0
- data/lib/fog/vsphere/models/compute/datacenter.rb +35 -0
- data/lib/fog/vsphere/models/compute/datacenters.rb +23 -0
- data/lib/fog/vsphere/models/compute/datastore.rb +24 -0
- data/lib/fog/vsphere/models/compute/datastores.rb +25 -0
- data/lib/fog/vsphere/models/compute/folder.rb +28 -0
- data/lib/fog/vsphere/models/compute/folders.rb +27 -0
- data/lib/fog/vsphere/models/compute/interface.rb +39 -0
- data/lib/fog/vsphere/models/compute/interfaces.rb +33 -0
- data/lib/fog/vsphere/models/compute/network.rb +21 -0
- data/lib/fog/vsphere/models/compute/networks.rb +25 -0
- data/lib/fog/vsphere/models/compute/resource_pool.rb +23 -0
- data/lib/fog/vsphere/models/compute/resource_pools.rb +26 -0
- data/lib/fog/vsphere/models/compute/server.rb +78 -12
- data/lib/fog/vsphere/models/compute/servers.rb +16 -20
- data/lib/fog/vsphere/models/compute/template.rb +13 -0
- data/lib/fog/vsphere/models/compute/templates.rb +23 -0
- data/lib/fog/vsphere/models/compute/volume.rb +45 -0
- data/lib/fog/vsphere/models/compute/volumes.rb +33 -0
- data/lib/fog/vsphere/requests/compute/create_vm.rb +114 -0
- data/lib/fog/vsphere/requests/compute/get_cluster.rb +25 -0
- data/lib/fog/vsphere/requests/compute/get_datacenter.rb +29 -0
- data/lib/fog/vsphere/requests/compute/get_datastore.rb +25 -0
- data/lib/fog/vsphere/requests/compute/get_folder.rb +73 -0
- data/lib/fog/vsphere/requests/compute/get_network.rb +25 -0
- data/lib/fog/vsphere/requests/compute/get_resource_pool.rb +26 -0
- data/lib/fog/vsphere/requests/compute/get_virtual_machine.rb +62 -0
- data/lib/fog/vsphere/requests/compute/list_clusters.rb +37 -0
- data/lib/fog/vsphere/requests/compute/list_datacenters.rb +34 -0
- data/lib/fog/vsphere/requests/compute/list_datastores.rb +40 -0
- data/lib/fog/vsphere/requests/compute/list_folders.rb +45 -0
- data/lib/fog/vsphere/requests/compute/list_networks.rb +38 -0
- data/lib/fog/vsphere/requests/compute/list_resource_pools.rb +39 -0
- data/lib/fog/vsphere/requests/compute/list_virtual_machines.rb +132 -166
- data/lib/fog/vsphere/requests/compute/list_vm_interfaces.rb +52 -0
- data/lib/fog/vsphere/requests/compute/list_vm_volumes.rb +51 -0
- data/lib/fog/vsphere/requests/compute/vm_clone.rb +6 -8
- data/lib/fog/vsphere/requests/compute/vm_destroy.rb +1 -8
- data/lib/fog/vsphere/requests/compute/vm_reconfig_hardware.rb +1 -2
- data/lib/tasks/changelog_task.rb +98 -0
- data/lib/tasks/documentation_task.rb +155 -0
- data/lib/tasks/test_task.rb +46 -0
- data/tests/aws/models/iam/users_tests.rb +16 -2
- data/tests/aws/requests/auto_scaling/notification_configuration_tests.rb +1 -0
- data/tests/aws/requests/auto_scaling/tag_tests.rb +1 -0
- data/tests/aws/requests/compute/instance_tests.rb +2 -0
- data/tests/aws/requests/compute/volume_tests.rb +8 -0
- data/tests/aws/requests/storage/object_tests.rb +18 -1
- data/tests/aws/requests/storage/versioning_tests.rb +70 -0
- data/tests/brightbox/compute_tests.rb +96 -4
- data/tests/brightbox/models/compute/account_tests.rb +15 -0
- data/tests/brightbox/oauth2_tests.rb +103 -0
- data/tests/brightbox/requests/compute/account_tests.rb +9 -2
- data/tests/brightbox/requests/compute/interface_tests.rb +18 -4
- data/tests/dns/models/record_tests.rb +17 -3
- data/tests/openstack/requests/compute/address_tests.rb +22 -19
- data/tests/openstack/requests/compute/flavor_tests.rb +4 -2
- data/tests/openstack/requests/compute/limit_tests.rb +60 -0
- data/tests/openstack/requests/compute/quota_tests.rb +16 -3
- data/tests/openstack/requests/compute/security_group_tests.rb +1 -1
- data/tests/rackspace/models/compute_v2/servers_tests.rb +6 -0
- data/tests/rackspace/models/storage/file_tests.rb +172 -0
- data/tests/rackspace/requests/dns/helper.rb +12 -26
- data/tests/vsphere/compute_tests.rb +3 -3
- data/tests/vsphere/models/compute/server_tests.rb +1 -2
- data/tests/vsphere/requests/compute/list_virtual_machines_tests.rb +5 -13
- data/tests/vsphere/requests/compute/vm_clone_tests.rb +2 -2
- metadata +59 -11
- data/lib/fog/vsphere/requests/compute/datacenters.rb +0 -34
- data/lib/fog/vsphere/requests/compute/find_vm_by_ref.rb +0 -41
- data/lib/fog/vsphere/requests/compute/vm_create.rb +0 -97
- data/tests/vsphere/requests/compute/find_vm_by_ref_tests.rb +0 -26
- data/tests/vsphere/requests/compute/vm_create_tests.rb +0 -20
@@ -2,7 +2,18 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new firewall policy for the account.
|
6
|
+
#
|
7
|
+
# Optionally applying to a server group at creation time.
|
8
|
+
#
|
9
|
+
# @param [Hash] options
|
10
|
+
# @option options [String] :server_group
|
11
|
+
# @option options [String] :name Editable label
|
12
|
+
#
|
13
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
14
|
+
#
|
15
|
+
# @see https://api.gb1.brightbox.com/1.0/#firewall_policy_create_firewall_policy
|
16
|
+
#
|
6
17
|
def create_firewall_policy(options)
|
7
18
|
request("post", "/1.0/firewall_policies", [201], options)
|
8
19
|
end
|
@@ -10,4 +21,4 @@ module Fog
|
|
10
21
|
end
|
11
22
|
end
|
12
23
|
end
|
13
|
-
end
|
24
|
+
end
|
@@ -2,7 +2,22 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new firewall rule for a firewall policy.
|
6
|
+
#
|
7
|
+
# @param [Hash] options
|
8
|
+
# @option options [String] :firewall_policy
|
9
|
+
# @option options [String] :protocol
|
10
|
+
# @option options [String] :source Required unless destination is set.
|
11
|
+
# @option options [String] :source_port
|
12
|
+
# @option options [String] :destination Required unless source is set
|
13
|
+
# @option options [String] :destination_port
|
14
|
+
# @option options [String] :icmp_type_name
|
15
|
+
# @option options [String] :description
|
16
|
+
#
|
17
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
18
|
+
#
|
19
|
+
# @see https://api.gb1.brightbox.com/1.0/#firewall_rule_create_firewall_rule
|
20
|
+
#
|
6
21
|
def create_firewall_rule(options)
|
7
22
|
request("post", "/1.0/firewall_rules", [202], options)
|
8
23
|
end
|
@@ -10,4 +25,4 @@ module Fog
|
|
10
25
|
end
|
11
26
|
end
|
12
27
|
end
|
13
|
-
end
|
28
|
+
end
|
@@ -2,7 +2,23 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new image for the account by registering it against an image stored within the Brightbox cloud image library.
|
6
|
+
#
|
7
|
+
# The disk image must be in place before you can attempt to create a reference in the API.
|
8
|
+
#
|
9
|
+
# @param [Hash] options
|
10
|
+
# @option options [String] :source Filename of the image file uploaded to /incoming via FTP
|
11
|
+
# @option options [String] :arch OS architecture this image is built for
|
12
|
+
# @option options [String] :name Name for this image. If no name is specified, a name will be autogenerated based on the source filename & current time. Can be modified later.
|
13
|
+
# @option options [String] :username Username for the image
|
14
|
+
# @option options [Boolean] :public
|
15
|
+
# @option options [Boolean] :compatibility_mode
|
16
|
+
# @option options [String] :description
|
17
|
+
#
|
18
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
19
|
+
#
|
20
|
+
# @see https://api.gb1.brightbox.com/1.0/#image_create_image
|
21
|
+
#
|
6
22
|
def create_image(options)
|
7
23
|
request("post", "/1.0/images", [201], options)
|
8
24
|
end
|
@@ -10,4 +26,4 @@ module Fog
|
|
10
26
|
end
|
11
27
|
end
|
12
28
|
end
|
13
|
-
end
|
29
|
+
end
|
@@ -2,7 +2,19 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new load balancer for the account.
|
6
|
+
#
|
7
|
+
# @param [Hash] options
|
8
|
+
# @option options [String] :name Editable label
|
9
|
+
# @option options [Array] :nodes Array of Node parameters
|
10
|
+
# @option options [String] :policy Method of Load balancing to use
|
11
|
+
# @option options [Array] :listeners What port to listen on, port to pass through to and protocol (tcp, http or http+ws) of listener. Timeout is optional and specified in milliseconds (default is 50000).
|
12
|
+
# @option options [String] :healthcheck Healthcheck options - only "port" and "type" required
|
13
|
+
#
|
14
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
15
|
+
#
|
16
|
+
# @see https://api.gb1.brightbox.com/1.0/#load_balancer_create_load_balancer
|
17
|
+
#
|
6
18
|
def create_load_balancer(options)
|
7
19
|
request("post", "/1.0/load_balancers", [202], options)
|
8
20
|
end
|
@@ -10,4 +22,4 @@ module Fog
|
|
10
22
|
end
|
11
23
|
end
|
12
24
|
end
|
13
|
-
end
|
25
|
+
end
|
@@ -2,7 +2,22 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new server for the account based on the required disk image.
|
6
|
+
#
|
7
|
+
# Optionally can setup the type of server, zone to locate it, groups to join and custom metadata.
|
8
|
+
#
|
9
|
+
# @param [Hash] options
|
10
|
+
# @option options [String] :image
|
11
|
+
# @option options [String] :name Editable label
|
12
|
+
# @option options [String] :server_type
|
13
|
+
# @option options [String] :zone Zone in which to create new Server
|
14
|
+
# @option options [String] :user_data
|
15
|
+
# @option options [Array] :server_groups Array of server groups to add server to
|
16
|
+
#
|
17
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
18
|
+
#
|
19
|
+
# @see https://api.gb1.brightbox.com/1.0/#server_create_server
|
20
|
+
#
|
6
21
|
def create_server(options)
|
7
22
|
request("post", "/1.0/servers", [202], options)
|
8
23
|
end
|
@@ -10,4 +25,4 @@ module Fog
|
|
10
25
|
end
|
11
26
|
end
|
12
27
|
end
|
13
|
-
end
|
28
|
+
end
|
@@ -2,7 +2,16 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Create a new server group for the account.
|
6
|
+
#
|
7
|
+
# @param [Hash] options
|
8
|
+
# @option options [String] :name Editable user label
|
9
|
+
# @option options [String] :description Editable user description
|
10
|
+
#
|
11
|
+
# @return [Hash, nil] The JSON response parsed to a Hash or nil if no options passed
|
12
|
+
#
|
13
|
+
# @see https://api.gb1.brightbox.com/1.0/#server_group_create_server_group
|
14
|
+
#
|
6
15
|
def create_server_group(options)
|
7
16
|
request("post", "/1.0/server_groups", [202], options)
|
8
17
|
end
|
@@ -10,4 +19,4 @@ module Fog
|
|
10
19
|
end
|
11
20
|
end
|
12
21
|
end
|
13
|
-
end
|
22
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the API client.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#api_client_destroy_api_client
|
12
|
+
#
|
6
13
|
def destroy_api_client(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/api_clients/#{identifier}", [200])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the application.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#application_destroy_application
|
12
|
+
#
|
6
13
|
def destroy_application(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/applications/#{identifier}", [200])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Release the cloud IP address from the account's ownership.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#cloud_ip_destroy_cloud_ip
|
12
|
+
#
|
6
13
|
def destroy_cloud_ip(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/cloud_ips/#{identifier}", [200])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the firewall policy if not in use.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#firewall_policy_destroy_firewall_policy
|
12
|
+
#
|
6
13
|
def destroy_firewall_policy(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/firewall_policies/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the firewall rule.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#firewall_rule_destroy_firewall_rule
|
12
|
+
#
|
6
13
|
def destroy_firewall_rule(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/firewall_rules/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the image.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#image_destroy_image
|
12
|
+
#
|
6
13
|
def destroy_image(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/images/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the LoadBalancer
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#load_balancer_destroy_load_balancer
|
12
|
+
#
|
6
13
|
def destroy_load_balancer(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/load_balancers/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the server and free up the resources.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#server_destroy_server
|
12
|
+
#
|
6
13
|
def destroy_server(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/servers/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Destroy the server group if not in use.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#server_group_destroy_server_group
|
12
|
+
#
|
6
13
|
def destroy_server_group(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("delete", "/1.0/server_groups/#{identifier}", [202])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,25 +2,17 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
#
|
5
|
+
# Get full details of the account.
|
6
6
|
#
|
7
|
-
#
|
7
|
+
# @overload get_account(identifier)
|
8
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
9
|
#
|
9
|
-
#
|
10
|
+
# @overload get_account()
|
11
|
+
# @deprecated Use {Fog::Compute::Brightbox::Real#get_scoped_account} instead
|
10
12
|
#
|
11
|
-
#
|
13
|
+
# @return [Hash] The JSON response parsed to a Hash
|
12
14
|
#
|
13
|
-
#
|
14
|
-
#
|
15
|
-
# === Notes:
|
16
|
-
#
|
17
|
-
# This also supports a deprecated form where if an identifier is not
|
18
|
-
# passed then the scoping account is returned instead. This should not
|
19
|
-
# be used in new code. Use #get_scoped_account instead.
|
20
|
-
#
|
21
|
-
# === Reference:
|
22
|
-
#
|
23
|
-
# https://api.gb1.brightbox.com/1.0/#account_get_account
|
15
|
+
# @see https://api.gb1.brightbox.com/1.0/#account_get_account
|
24
16
|
#
|
25
17
|
def get_account(identifier = nil)
|
26
18
|
if identifier.nil? || identifier.empty?
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Get full details of the API client.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#api_client_get_api_client
|
12
|
+
#
|
6
13
|
def get_api_client(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("get", "/1.0/api_clients/#{identifier}", [200])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|
@@ -2,7 +2,14 @@ module Fog
|
|
2
2
|
module Compute
|
3
3
|
class Brightbox
|
4
4
|
class Real
|
5
|
-
|
5
|
+
# Get full details of the application.
|
6
|
+
#
|
7
|
+
# @param [String] identifier Unique reference to identify the resource
|
8
|
+
#
|
9
|
+
# @return [Hash] The JSON response parsed to a Hash
|
10
|
+
#
|
11
|
+
# @see https://api.gb1.brightbox.com/1.0/#application_get_application
|
12
|
+
#
|
6
13
|
def get_application(identifier)
|
7
14
|
return nil if identifier.nil? || identifier == ""
|
8
15
|
request("get", "/1.0/applications/#{identifier}", [200])
|
@@ -11,4 +18,4 @@ module Fog
|
|
11
18
|
end
|
12
19
|
end
|
13
20
|
end
|
14
|
-
end
|
21
|
+
end
|