fog-brightbox 1.0.0.rc1 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (237) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +2 -2
  3. data/CHANGELOG.md +58 -2
  4. data/README.md +3 -4
  5. data/fog-brightbox.gemspec +2 -2
  6. data/lib/fog/brightbox.rb +4 -24
  7. data/lib/fog/brightbox/compute.rb +18 -33
  8. data/lib/fog/brightbox/compute/config.rb +1 -1
  9. data/lib/fog/brightbox/compute/image_selector.rb +5 -3
  10. data/lib/fog/brightbox/compute/resource_locking.rb +1 -1
  11. data/lib/fog/brightbox/compute/shared.rb +3 -3
  12. data/lib/fog/brightbox/models/compute/account.rb +2 -2
  13. data/lib/fog/brightbox/models/compute/accounts.rb +3 -3
  14. data/lib/fog/brightbox/models/compute/api_client.rb +3 -3
  15. data/lib/fog/brightbox/models/compute/api_clients.rb +3 -3
  16. data/lib/fog/brightbox/models/compute/application.rb +2 -2
  17. data/lib/fog/brightbox/models/compute/applications.rb +3 -3
  18. data/lib/fog/brightbox/models/compute/cloud_ip.rb +3 -3
  19. data/lib/fog/brightbox/models/compute/cloud_ips.rb +3 -3
  20. data/lib/fog/brightbox/models/compute/collaboration.rb +3 -3
  21. data/lib/fog/brightbox/models/compute/collaborations.rb +5 -5
  22. data/lib/fog/brightbox/models/compute/database_server.rb +6 -3
  23. data/lib/fog/brightbox/models/compute/database_servers.rb +3 -3
  24. data/lib/fog/brightbox/models/compute/database_snapshot.rb +3 -3
  25. data/lib/fog/brightbox/models/compute/database_snapshots.rb +3 -3
  26. data/lib/fog/brightbox/models/compute/database_type.rb +2 -2
  27. data/lib/fog/brightbox/models/compute/database_types.rb +3 -3
  28. data/lib/fog/brightbox/models/compute/event.rb +2 -2
  29. data/lib/fog/brightbox/models/compute/events.rb +3 -3
  30. data/lib/fog/brightbox/models/compute/firewall_policies.rb +3 -3
  31. data/lib/fog/brightbox/models/compute/firewall_policy.rb +3 -3
  32. data/lib/fog/brightbox/models/compute/firewall_rule.rb +3 -3
  33. data/lib/fog/brightbox/models/compute/firewall_rules.rb +3 -3
  34. data/lib/fog/brightbox/models/compute/flavor.rb +2 -2
  35. data/lib/fog/brightbox/models/compute/flavors.rb +3 -3
  36. data/lib/fog/brightbox/models/compute/image.rb +3 -3
  37. data/lib/fog/brightbox/models/compute/images.rb +3 -3
  38. data/lib/fog/brightbox/models/compute/load_balancer.rb +6 -3
  39. data/lib/fog/brightbox/models/compute/load_balancers.rb +3 -3
  40. data/lib/fog/brightbox/models/compute/server.rb +6 -3
  41. data/lib/fog/brightbox/models/compute/server_group.rb +3 -3
  42. data/lib/fog/brightbox/models/compute/server_groups.rb +3 -3
  43. data/lib/fog/brightbox/models/compute/servers.rb +4 -4
  44. data/lib/fog/brightbox/models/compute/user.rb +2 -2
  45. data/lib/fog/brightbox/models/compute/user_collaboration.rb +3 -3
  46. data/lib/fog/brightbox/models/compute/user_collaborations.rb +4 -4
  47. data/lib/fog/brightbox/models/compute/users.rb +3 -3
  48. data/lib/fog/brightbox/models/compute/zone.rb +2 -2
  49. data/lib/fog/brightbox/models/compute/zones.rb +3 -3
  50. data/lib/fog/brightbox/models/storage/directories.rb +4 -4
  51. data/lib/fog/brightbox/models/storage/directory.rb +3 -3
  52. data/lib/fog/brightbox/models/storage/file.rb +2 -2
  53. data/lib/fog/brightbox/models/storage/files.rb +6 -6
  54. data/lib/fog/brightbox/requests/compute/accept_user_collaboration.rb +2 -2
  55. data/lib/fog/brightbox/requests/compute/activate_console_server.rb +2 -2
  56. data/lib/fog/brightbox/requests/compute/add_listeners_load_balancer.rb +2 -2
  57. data/lib/fog/brightbox/requests/compute/add_nodes_load_balancer.rb +2 -2
  58. data/lib/fog/brightbox/requests/compute/add_servers_server_group.rb +2 -2
  59. data/lib/fog/brightbox/requests/compute/apply_to_firewall_policy.rb +2 -2
  60. data/lib/fog/brightbox/requests/compute/create_api_client.rb +2 -2
  61. data/lib/fog/brightbox/requests/compute/create_application.rb +2 -2
  62. data/lib/fog/brightbox/requests/compute/create_cloud_ip.rb +2 -2
  63. data/lib/fog/brightbox/requests/compute/create_collaboration.rb +2 -2
  64. data/lib/fog/brightbox/requests/compute/create_database_server.rb +2 -2
  65. data/lib/fog/brightbox/requests/compute/create_firewall_policy.rb +2 -2
  66. data/lib/fog/brightbox/requests/compute/create_firewall_rule.rb +2 -2
  67. data/lib/fog/brightbox/requests/compute/create_image.rb +2 -2
  68. data/lib/fog/brightbox/requests/compute/create_load_balancer.rb +2 -2
  69. data/lib/fog/brightbox/requests/compute/create_server.rb +2 -2
  70. data/lib/fog/brightbox/requests/compute/create_server_group.rb +2 -2
  71. data/lib/fog/brightbox/requests/compute/delete_api_client.rb +2 -10
  72. data/lib/fog/brightbox/requests/compute/delete_application.rb +2 -10
  73. data/lib/fog/brightbox/requests/compute/delete_cloud_ip.rb +2 -10
  74. data/lib/fog/brightbox/requests/compute/delete_collaboration.rb +2 -10
  75. data/lib/fog/brightbox/requests/compute/delete_database_server.rb +2 -10
  76. data/lib/fog/brightbox/requests/compute/delete_database_snapshot.rb +2 -10
  77. data/lib/fog/brightbox/requests/compute/delete_firewall_policy.rb +2 -10
  78. data/lib/fog/brightbox/requests/compute/delete_firewall_rule.rb +2 -10
  79. data/lib/fog/brightbox/requests/compute/delete_image.rb +2 -10
  80. data/lib/fog/brightbox/requests/compute/delete_load_balancer.rb +2 -10
  81. data/lib/fog/brightbox/requests/compute/delete_server.rb +2 -10
  82. data/lib/fog/brightbox/requests/compute/delete_server_group.rb +2 -10
  83. data/lib/fog/brightbox/requests/compute/delete_user_collaboration.rb +2 -10
  84. data/lib/fog/brightbox/requests/compute/get_account.rb +6 -15
  85. data/lib/fog/brightbox/requests/compute/get_api_client.rb +2 -2
  86. data/lib/fog/brightbox/requests/compute/get_application.rb +2 -2
  87. data/lib/fog/brightbox/requests/compute/get_authenticated_user.rb +2 -2
  88. data/lib/fog/brightbox/requests/compute/get_cloud_ip.rb +2 -2
  89. data/lib/fog/brightbox/requests/compute/get_collaboration.rb +2 -2
  90. data/lib/fog/brightbox/requests/compute/get_database_server.rb +2 -2
  91. data/lib/fog/brightbox/requests/compute/get_database_snapshot.rb +2 -2
  92. data/lib/fog/brightbox/requests/compute/get_database_type.rb +2 -2
  93. data/lib/fog/brightbox/requests/compute/get_firewall_policy.rb +2 -2
  94. data/lib/fog/brightbox/requests/compute/get_firewall_rule.rb +2 -2
  95. data/lib/fog/brightbox/requests/compute/get_image.rb +2 -2
  96. data/lib/fog/brightbox/requests/compute/get_interface.rb +2 -2
  97. data/lib/fog/brightbox/requests/compute/get_load_balancer.rb +2 -2
  98. data/lib/fog/brightbox/requests/compute/get_scoped_account.rb +2 -2
  99. data/lib/fog/brightbox/requests/compute/get_server.rb +2 -2
  100. data/lib/fog/brightbox/requests/compute/get_server_group.rb +2 -2
  101. data/lib/fog/brightbox/requests/compute/get_server_type.rb +2 -2
  102. data/lib/fog/brightbox/requests/compute/get_user.rb +6 -15
  103. data/lib/fog/brightbox/requests/compute/get_user_collaboration.rb +2 -2
  104. data/lib/fog/brightbox/requests/compute/get_zone.rb +2 -2
  105. data/lib/fog/brightbox/requests/compute/list_accounts.rb +2 -2
  106. data/lib/fog/brightbox/requests/compute/list_api_clients.rb +2 -2
  107. data/lib/fog/brightbox/requests/compute/list_applications.rb +2 -2
  108. data/lib/fog/brightbox/requests/compute/list_cloud_ips.rb +2 -2
  109. data/lib/fog/brightbox/requests/compute/list_collaborations.rb +2 -2
  110. data/lib/fog/brightbox/requests/compute/list_database_servers.rb +2 -2
  111. data/lib/fog/brightbox/requests/compute/list_database_snapshots.rb +2 -2
  112. data/lib/fog/brightbox/requests/compute/list_database_types.rb +2 -2
  113. data/lib/fog/brightbox/requests/compute/list_events.rb +2 -2
  114. data/lib/fog/brightbox/requests/compute/list_firewall_policies.rb +2 -2
  115. data/lib/fog/brightbox/requests/compute/list_images.rb +2 -2
  116. data/lib/fog/brightbox/requests/compute/list_load_balancers.rb +2 -2
  117. data/lib/fog/brightbox/requests/compute/list_server_groups.rb +2 -2
  118. data/lib/fog/brightbox/requests/compute/list_server_types.rb +2 -2
  119. data/lib/fog/brightbox/requests/compute/list_servers.rb +2 -2
  120. data/lib/fog/brightbox/requests/compute/list_user_collaborations.rb +2 -2
  121. data/lib/fog/brightbox/requests/compute/list_users.rb +2 -2
  122. data/lib/fog/brightbox/requests/compute/list_zones.rb +2 -2
  123. data/lib/fog/brightbox/requests/compute/lock_resource_database_server.rb +2 -2
  124. data/lib/fog/brightbox/requests/compute/lock_resource_database_snapshot.rb +2 -2
  125. data/lib/fog/brightbox/requests/compute/lock_resource_image.rb +2 -2
  126. data/lib/fog/brightbox/requests/compute/lock_resource_load_balancer.rb +2 -2
  127. data/lib/fog/brightbox/requests/compute/lock_resource_server.rb +2 -2
  128. data/lib/fog/brightbox/requests/compute/map_cloud_ip.rb +2 -2
  129. data/lib/fog/brightbox/requests/compute/move_servers_server_group.rb +2 -2
  130. data/lib/fog/brightbox/requests/compute/reboot_server.rb +2 -2
  131. data/lib/fog/brightbox/requests/compute/reject_user_collaboration.rb +2 -2
  132. data/lib/fog/brightbox/requests/compute/remove_firewall_policy.rb +2 -2
  133. data/lib/fog/brightbox/requests/compute/remove_listeners_load_balancer.rb +2 -2
  134. data/lib/fog/brightbox/requests/compute/remove_nodes_load_balancer.rb +2 -2
  135. data/lib/fog/brightbox/requests/compute/remove_servers_server_group.rb +2 -2
  136. data/lib/fog/brightbox/requests/compute/resend_collaboration.rb +2 -2
  137. data/lib/fog/brightbox/requests/compute/reset_ftp_password_account.rb +6 -15
  138. data/lib/fog/brightbox/requests/compute/reset_ftp_password_scoped_account.rb +2 -2
  139. data/lib/fog/brightbox/requests/compute/reset_password_database_server.rb +2 -2
  140. data/lib/fog/brightbox/requests/compute/reset_secret_api_client.rb +2 -2
  141. data/lib/fog/brightbox/requests/compute/reset_secret_application.rb +2 -2
  142. data/lib/fog/brightbox/requests/compute/reset_server.rb +2 -2
  143. data/lib/fog/brightbox/requests/compute/shutdown_server.rb +2 -2
  144. data/lib/fog/brightbox/requests/compute/snapshot_database_server.rb +2 -2
  145. data/lib/fog/brightbox/requests/compute/snapshot_server.rb +2 -2
  146. data/lib/fog/brightbox/requests/compute/start_server.rb +2 -2
  147. data/lib/fog/brightbox/requests/compute/stop_server.rb +2 -2
  148. data/lib/fog/brightbox/requests/compute/unlock_resource_database_server.rb +2 -2
  149. data/lib/fog/brightbox/requests/compute/unlock_resource_database_snapshot.rb +2 -2
  150. data/lib/fog/brightbox/requests/compute/unlock_resource_image.rb +2 -2
  151. data/lib/fog/brightbox/requests/compute/unlock_resource_load_balancer.rb +2 -2
  152. data/lib/fog/brightbox/requests/compute/unlock_resource_server.rb +2 -2
  153. data/lib/fog/brightbox/requests/compute/unmap_cloud_ip.rb +2 -2
  154. data/lib/fog/brightbox/requests/compute/update_account.rb +15 -36
  155. data/lib/fog/brightbox/requests/compute/update_api_client.rb +2 -2
  156. data/lib/fog/brightbox/requests/compute/update_application.rb +2 -2
  157. data/lib/fog/brightbox/requests/compute/update_cloud_ip.rb +2 -2
  158. data/lib/fog/brightbox/requests/compute/update_database_server.rb +2 -2
  159. data/lib/fog/brightbox/requests/compute/update_database_snapshot.rb +2 -2
  160. data/lib/fog/brightbox/requests/compute/update_firewall_policy.rb +2 -2
  161. data/lib/fog/brightbox/requests/compute/update_firewall_rule.rb +2 -2
  162. data/lib/fog/brightbox/requests/compute/update_image.rb +2 -2
  163. data/lib/fog/brightbox/requests/compute/update_load_balancer.rb +2 -2
  164. data/lib/fog/brightbox/requests/compute/update_scoped_account.rb +2 -2
  165. data/lib/fog/brightbox/requests/compute/update_server.rb +2 -2
  166. data/lib/fog/brightbox/requests/compute/update_server_group.rb +2 -2
  167. data/lib/fog/brightbox/requests/compute/update_user.rb +2 -2
  168. data/lib/fog/brightbox/requests/storage/copy_object.rb +3 -3
  169. data/lib/fog/brightbox/requests/storage/delete_container.rb +3 -3
  170. data/lib/fog/brightbox/requests/storage/delete_multiple_objects.rb +2 -2
  171. data/lib/fog/brightbox/requests/storage/delete_object.rb +3 -3
  172. data/lib/fog/brightbox/requests/storage/delete_static_large_object.rb +3 -3
  173. data/lib/fog/brightbox/requests/storage/get_container.rb +3 -3
  174. data/lib/fog/brightbox/requests/storage/get_containers.rb +2 -2
  175. data/lib/fog/brightbox/requests/storage/get_object.rb +3 -3
  176. data/lib/fog/brightbox/requests/storage/get_object_http_url.rb +2 -2
  177. data/lib/fog/brightbox/requests/storage/get_object_https_url.rb +2 -2
  178. data/lib/fog/brightbox/requests/storage/head_container.rb +3 -3
  179. data/lib/fog/brightbox/requests/storage/head_containers.rb +2 -2
  180. data/lib/fog/brightbox/requests/storage/head_object.rb +3 -3
  181. data/lib/fog/brightbox/requests/storage/post_set_meta_temp_url_key.rb +2 -2
  182. data/lib/fog/brightbox/requests/storage/put_container.rb +3 -3
  183. data/lib/fog/brightbox/requests/storage/put_dynamic_obj_manifest.rb +5 -5
  184. data/lib/fog/brightbox/requests/storage/put_object.rb +3 -3
  185. data/lib/fog/brightbox/requests/storage/put_object_manifest.rb +2 -2
  186. data/lib/fog/brightbox/requests/storage/put_static_obj_manifest.rb +4 -4
  187. data/lib/fog/brightbox/storage.rb +12 -5
  188. data/lib/fog/brightbox/storage/authentication_request.rb +1 -1
  189. data/lib/fog/brightbox/storage/authentication_required.rb +1 -1
  190. data/lib/fog/brightbox/storage/config.rb +1 -1
  191. data/lib/fog/brightbox/storage/connection.rb +2 -2
  192. data/lib/fog/brightbox/storage/management_url_unknown.rb +1 -1
  193. data/lib/fog/brightbox/storage/not_found.rb +8 -0
  194. data/lib/fog/brightbox/version.rb +1 -1
  195. data/spec/fog/brightbox/compute/wrapped_request_spec.rb +4 -4
  196. data/spec/fog/brightbox/config_spec.rb +3 -3
  197. data/spec/fog/brightbox/link_helper_spec.rb +1 -1
  198. data/spec/fog/brightbox/storage/authentication_request_spec.rb +4 -4
  199. data/spec/fog/brightbox/storage/connection_errors_spec.rb +1 -1
  200. data/spec/fog/brightbox/storage/connection_spec.rb +2 -2
  201. data/spec/fog/compute/brightbox/account_spec.rb +1 -1
  202. data/spec/fog/compute/brightbox/api_client_spec.rb +1 -1
  203. data/spec/fog/compute/brightbox/application_spec.rb +1 -1
  204. data/spec/fog/compute/brightbox/cloud_ip_spec.rb +1 -1
  205. data/spec/fog/compute/brightbox/collaboration_spec.rb +1 -1
  206. data/spec/fog/compute/brightbox/database_server_spec.rb +20 -5
  207. data/spec/fog/compute/brightbox/database_snapshot_spec.rb +1 -1
  208. data/spec/fog/compute/brightbox/database_type_spec.rb +1 -1
  209. data/spec/fog/compute/brightbox/event_spec.rb +1 -1
  210. data/spec/fog/compute/brightbox/firewall_policy_spec.rb +1 -1
  211. data/spec/fog/compute/brightbox/flavor_spec.rb +1 -1
  212. data/spec/fog/compute/brightbox/image_spec.rb +1 -1
  213. data/spec/fog/compute/brightbox/load_balancer_spec.rb +25 -1
  214. data/spec/fog/compute/brightbox/server_group_spec.rb +1 -1
  215. data/spec/fog/compute/brightbox/server_spec.rb +47 -5
  216. data/spec/fog/compute/brightbox/user_collaboration_spec.rb +1 -1
  217. data/spec/fog/compute/brightbox/user_spec.rb +1 -1
  218. data/spec/fog/compute/brightbox/zone_spec.rb +1 -1
  219. data/spec/fog/compute/brightbox_spec.rb +5 -5
  220. data/spec/fog/storage/brightbox_spec.rb +8 -8
  221. data/spec/model_setup.rb +1 -1
  222. data/tests/brightbox/compute/schema.rb +1 -1
  223. data/tests/brightbox/compute_tests.rb +2 -2
  224. data/tests/brightbox/requests/compute/api_client_tests.rb +2 -2
  225. data/tests/brightbox/requests/compute/application_test.rb +2 -2
  226. data/tests/brightbox/requests/compute/cloud_ip_tests.rb +2 -2
  227. data/tests/brightbox/requests/compute/collaboration_tests.rb +6 -3
  228. data/tests/brightbox/requests/compute/database_server_tests.rb +2 -2
  229. data/tests/brightbox/requests/compute/database_snapsnot_tests.rb +2 -2
  230. data/tests/brightbox/requests/compute/firewall_policy_tests.rb +2 -2
  231. data/tests/brightbox/requests/compute/firewall_rule_tests.rb +2 -2
  232. data/tests/brightbox/requests/compute/helper.rb +1 -1
  233. data/tests/brightbox/requests/compute/image_tests.rb +2 -2
  234. data/tests/brightbox/requests/compute/load_balancer_tests.rb +2 -2
  235. data/tests/brightbox/requests/compute/server_group_tests.rb +2 -2
  236. data/tests/brightbox/requests/compute/server_tests.rb +2 -2
  237. metadata +20 -14
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class DatabaseServer < Fog::Brightbox::Model
5
5
  include Fog::Brightbox::Compute::ResourceLocking
6
6
 
@@ -34,6 +34,8 @@ module Fog
34
34
  attribute :flavor_id, "alias" => "database_server_type", :squash => "id"
35
35
  attribute :zone_id, "alias" => "zone", :squash => "id"
36
36
 
37
+ attribute :snapshot_id
38
+
37
39
  attribute :cloud_ips
38
40
 
39
41
  def save
@@ -54,6 +56,7 @@ module Fog
54
56
  options[:version] = database_version if database_version
55
57
  options[:database_type] = flavor_id if flavor_id
56
58
  options[:zone] = zone_id if zone_id
59
+ options[:snapshot] = snapshot_id if snapshot_id
57
60
 
58
61
  data = create_database_server(options)
59
62
  end
@@ -81,7 +84,7 @@ module Fog
81
84
 
82
85
  def destroy
83
86
  requires :identity
84
- merge_attributes(service.destroy_database_server(identity))
87
+ merge_attributes(service.delete_database_server(identity))
85
88
  true
86
89
  end
87
90
 
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/database_server"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class DatabaseServers < Fog::Collection
7
- model Fog::Compute::Brightbox::DatabaseServer
7
+ model Fog::Brightbox::Compute::DatabaseServer
8
8
 
9
9
  def all
10
10
  data = service.list_database_servers
@@ -1,8 +1,8 @@
1
1
  require "fog/brightbox/compute/resource_locking"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class DatabaseSnapshot < Fog::Brightbox::Model
7
7
  include Fog::Brightbox::Compute::ResourceLocking
8
8
 
@@ -39,7 +39,7 @@ module Fog
39
39
 
40
40
  def destroy
41
41
  requires :identity
42
- merge_attributes(service.destroy_database_snapshot(identity))
42
+ merge_attributes(service.delete_database_snapshot(identity))
43
43
  true
44
44
  end
45
45
 
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/database_snapshot"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class DatabaseSnapshots < Fog::Collection
7
- model Fog::Compute::Brightbox::DatabaseSnapshot
7
+ model Fog::Brightbox::Compute::DatabaseSnapshot
8
8
 
9
9
  def all
10
10
  data = service.list_database_snapshots
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class DatabaseType < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :url
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/database_type"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class DatabaseTypes < Fog::Collection
7
- model Fog::Compute::Brightbox::DatabaseType
7
+ model Fog::Brightbox::Compute::DatabaseType
8
8
 
9
9
  def all
10
10
  data = service.list_database_types
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  # @api private
5
5
  class Event < Fog::Brightbox::Model
6
6
  identity :id
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/event"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class Events < Fog::Collection
7
- model Fog::Compute::Brightbox::Event
7
+ model Fog::Brightbox::Compute::Event
8
8
 
9
9
  def all
10
10
  data = service.list_events
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/firewall_policy"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class FirewallPolicies < Fog::Collection
7
- model Fog::Compute::Brightbox::FirewallPolicy
7
+ model Fog::Brightbox::Compute::FirewallPolicy
8
8
 
9
9
  def all
10
10
  data = service.list_firewall_policies
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class FirewallPolicy < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :url
@@ -50,7 +50,7 @@ module Fog
50
50
 
51
51
  def destroy
52
52
  requires :identity
53
- service.destroy_firewall_policy(identity)
53
+ service.delete_firewall_policy(identity)
54
54
  true
55
55
  end
56
56
  end
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class FirewallRule < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :url
@@ -39,7 +39,7 @@ module Fog
39
39
 
40
40
  def destroy
41
41
  requires :identity
42
- service.destroy_firewall_rule(identity)
42
+ service.delete_firewall_rule(identity)
43
43
  true
44
44
  end
45
45
  end
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/firewall_rule"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class FirewallRules < Fog::Collection
7
- model Fog::Compute::Brightbox::FirewallRule
7
+ model Fog::Brightbox::Compute::FirewallRule
8
8
 
9
9
  def get(identifier)
10
10
  return nil if identifier.nil? || identifier == ""
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class Flavor < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :url
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/flavor"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class Flavors < Fog::Collection
7
- model Fog::Compute::Brightbox::Flavor
7
+ model Fog::Brightbox::Compute::Flavor
8
8
 
9
9
  def all
10
10
  data = service.list_server_types
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class Image < Fog::Brightbox::Model
5
5
  include Fog::Brightbox::Compute::ResourceLocking
6
6
 
@@ -53,7 +53,7 @@ module Fog
53
53
 
54
54
  def destroy
55
55
  requires :identity
56
- service.destroy_image(identity)
56
+ service.delete_image(identity)
57
57
  true
58
58
  end
59
59
  end
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/image"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class Images < Fog::Collection
7
- model Fog::Compute::Brightbox::Image
7
+ model Fog::Brightbox::Compute::Image
8
8
 
9
9
  def all
10
10
  data = service.list_images
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class LoadBalancer < Fog::Brightbox::Model
5
5
  include Fog::Brightbox::Compute::ResourceLocking
6
6
 
@@ -18,6 +18,8 @@ module Fog
18
18
  attribute :healthcheck
19
19
  attribute :listeners
20
20
 
21
+ attribute :ssl_minimum_version
22
+
21
23
  # These SSL attributes act only as setters. You can not read certs or keys via the API
22
24
  attribute :certificate_pem
23
25
  attribute :certificate_private_key
@@ -58,6 +60,7 @@ module Fog
58
60
  :buffer_size => buffer_size,
59
61
  :certificate_pem => certificate_pem,
60
62
  :certificate_private_key => certificate_private_key,
63
+ :ssl_minimum_version => ssl_minimum_version,
61
64
  :sslv3 => ssl3?
62
65
  }.delete_if { |_k, v| v.nil? || v == "" }
63
66
  data = service.create_load_balancer(options)
@@ -67,7 +70,7 @@ module Fog
67
70
 
68
71
  def destroy
69
72
  requires :identity
70
- service.destroy_load_balancer(identity)
73
+ service.delete_load_balancer(identity)
71
74
  true
72
75
  end
73
76
 
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/load_balancer"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class LoadBalancers < Fog::Collection
7
- model Fog::Compute::Brightbox::LoadBalancer
7
+ model Fog::Brightbox::Compute::LoadBalancer
8
8
 
9
9
  def all
10
10
  data = service.list_load_balancers
@@ -1,8 +1,8 @@
1
1
  require "fog/compute/models/server"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class Server < Fog::Compute::Server
7
7
  include Fog::Brightbox::ModelHelper
8
8
  include Fog::Brightbox::Compute::ResourceLocking
@@ -21,6 +21,8 @@ module Fog
21
21
  attribute :fqdn
22
22
  attribute :console_token
23
23
 
24
+ attribute :disk_encrypted
25
+
24
26
  # Times
25
27
  attribute :created_at, :type => :time
26
28
  attribute :started_at, :type => :time
@@ -127,7 +129,7 @@ module Fog
127
129
 
128
130
  def destroy
129
131
  requires :identity
130
- service.destroy_server(identity)
132
+ service.delete_server(identity)
131
133
  true
132
134
  end
133
135
 
@@ -188,6 +190,7 @@ module Fog
188
190
 
189
191
  options.merge!(:server_type => flavor_id) unless flavor_id.nil? || flavor_id == ""
190
192
  options.merge!(:cloud_ip => cloud_ip) unless cloud_ip.nil? || cloud_ip == ""
193
+ options.merge!(:disk_encrypted => disk_encrypted) if disk_encrypted
191
194
 
192
195
  data = service.create_server(options)
193
196
  merge_attributes(data)
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  # A server group is a collection of servers
5
5
  #
6
6
  # Certain actions can accept a server group and affect all members
@@ -76,7 +76,7 @@ module Fog
76
76
 
77
77
  def destroy
78
78
  requires :identity
79
- service.destroy_server_group(identity)
79
+ service.delete_server_group(identity)
80
80
  true
81
81
  end
82
82
 
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/server_group"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class ServerGroups < Fog::Collection
7
- model Fog::Compute::Brightbox::ServerGroup
7
+ model Fog::Brightbox::Compute::ServerGroup
8
8
 
9
9
  def all
10
10
  data = service.list_server_groups
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/server"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class Servers < Fog::Collection
7
- model Fog::Compute::Brightbox::Server
7
+ model Fog::Brightbox::Compute::Server
8
8
 
9
9
  def all
10
10
  data = service.list_servers
@@ -26,7 +26,7 @@ module Fog
26
26
  # @option options [String] zone_id Identifer for preferred zone to locate server in
27
27
  # @option options [Array<String>] server_groups List of group identifiers for the server to join
28
28
  #
29
- # @return Fog::Compute::Brightbox::Server
29
+ # @return Fog::Brightbox::Compute::Server
30
30
  #
31
31
  def bootstrap(options = {})
32
32
  server = create(options)
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class User < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :resource_type
@@ -1,6 +1,6 @@
1
1
  module Fog
2
- module Compute
3
- class Brightbox
2
+ module Brightbox
3
+ class Compute
4
4
  class UserCollaboration < Fog::Brightbox::Model
5
5
  identity :id
6
6
  attribute :status
@@ -31,7 +31,7 @@ module Fog
31
31
 
32
32
  def destroy
33
33
  requires :identity
34
- data = service.destroy_user_collaboration(identity)
34
+ data = service.delete_user_collaboration(identity)
35
35
  merge_attributes(data)
36
36
  true
37
37
  end
@@ -1,10 +1,10 @@
1
1
  require "fog/brightbox/models/compute/user_collaboration"
2
2
 
3
3
  module Fog
4
- module Compute
5
- class Brightbox
4
+ module Brightbox
5
+ class Compute
6
6
  class UserCollaborations < Fog::Collection
7
- model Fog::Compute::Brightbox::UserCollaboration
7
+ model Fog::Brightbox::Compute::UserCollaboration
8
8
 
9
9
  def all
10
10
  data = service.list_user_collaborations
@@ -21,7 +21,7 @@ module Fog
21
21
 
22
22
  def destroy
23
23
  requires :identity
24
- service.destroy_user_collaboration(identity)
24
+ service.delete_user_collaboration(identity)
25
25
  true
26
26
  end
27
27
  end