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.
Files changed (229) hide show
  1. data/.gitignore +1 -1
  2. data/brightbox-cli.gemspec +10 -9
  3. data/lib/brightbox-cli/commands/servers-activate-console.rb +1 -1
  4. data/lib/brightbox-cli/commands/types-show.rb +5 -4
  5. data/lib/brightbox-cli/config.rb +1 -1
  6. data/lib/brightbox-cli/detailed_server.rb +2 -1
  7. data/lib/brightbox-cli/gli_global_hooks.rb +1 -8
  8. data/lib/brightbox-cli/server_groups.rb +4 -0
  9. data/lib/brightbox-cli/servers.rb +5 -13
  10. data/lib/brightbox-cli/types.rb +1 -1
  11. data/lib/brightbox-cli/vendor/fog/.gitignore +1 -0
  12. data/lib/brightbox-cli/vendor/fog/README.rdoc +1 -1
  13. data/lib/brightbox-cli/vendor/fog/Rakefile +4 -3
  14. data/lib/brightbox-cli/vendor/fog/changelog.txt +213 -0
  15. data/lib/brightbox-cli/vendor/fog/docs/compute/index.markdown +15 -1
  16. data/lib/brightbox-cli/vendor/fog/docs/index.markdown +1 -1
  17. data/lib/brightbox-cli/vendor/fog/docs/storage/index.markdown +4 -4
  18. data/lib/brightbox-cli/vendor/fog/examples/compute_tests.rb +18 -6
  19. data/lib/brightbox-cli/vendor/fog/examples/dns_tests.rb +1 -1
  20. data/lib/brightbox-cli/vendor/fog/examples/storage_tests.rb +1 -1
  21. data/lib/brightbox-cli/vendor/fog/fog.gemspec +4 -3
  22. data/lib/brightbox-cli/vendor/fog/lib/fog.rb +1 -1
  23. data/lib/brightbox-cli/vendor/fog/lib/fog/aws.rb +16 -1
  24. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/auto_scaling.rb +2 -17
  25. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/cloud_formation.rb +1 -16
  26. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/cloud_watch.rb +2 -17
  27. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/compute.rb +10 -21
  28. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/elasticache.rb +1 -7
  29. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/elb.rb +34 -24
  30. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/emr.rb +5 -4
  31. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/iam.rb +16 -1
  32. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/auto_scaling/group.rb +2 -2
  33. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/cloud_watch/metric_statistic.rb +1 -2
  34. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/security_group.rb +3 -3
  35. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/security_groups.rb +25 -0
  36. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/compute/server.rb +4 -1
  37. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/dns/records.rb +3 -3
  38. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/elb/listener.rb +9 -7
  39. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/elb/load_balancer.rb +6 -0
  40. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/directory.rb +21 -0
  41. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/file.rb +19 -5
  42. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/models/storage/files.rb +4 -4
  43. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/compute/describe_instances.rb +2 -2
  44. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/compute/describe_security_groups.rb +2 -2
  45. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/parsers/sqs/receive_message.rb +1 -1
  46. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/rds.rb +41 -18
  47. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/create_security_group.rb +6 -4
  48. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/create_tags.rb +3 -2
  49. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/describe_availability_zones.rb +3 -0
  50. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/compute/describe_security_groups.rb +2 -0
  51. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_app_cookie_stickiness_policy.rb +2 -0
  52. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_lb_cookie_stickiness_policy.rb +3 -1
  53. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_load_balancer.rb +7 -2
  54. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/create_load_balancer_listeners.rb +10 -1
  55. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/delete_load_balancer_policy.rb +1 -1
  56. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/describe_load_balancers.rb +5 -1
  57. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/set_load_balancer_listener_ssl_certificate.rb +27 -0
  58. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/elb/set_load_balancer_policies_of_listener.rb +1 -1
  59. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/emr/run_job_flow.rb +9 -7
  60. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/add_user_to_group.rb +24 -0
  61. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_access_key.rb +24 -0
  62. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_group.rb +21 -0
  63. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/create_user.rb +21 -0
  64. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_access_key.rb +17 -0
  65. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_group.rb +19 -0
  66. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_user.rb +17 -0
  67. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/delete_user_policy.rb +16 -0
  68. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_access_keys.rb +21 -0
  69. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_groups.rb +18 -0
  70. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_groups_for_user.rb +24 -0
  71. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_user_policies.rb +18 -0
  72. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/list_users.rb +17 -0
  73. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/put_user_policy.rb +18 -0
  74. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/remove_user_from_group.rb +19 -0
  75. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/iam/upload_server_certificate.rb +1 -1
  76. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/authorize_db_security_group_ingress.rb +30 -1
  77. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/create_db_instance.rb +67 -1
  78. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/create_db_security_group.rb +19 -1
  79. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/delete_db_instance.rb +19 -3
  80. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/delete_db_security_group.rb +11 -1
  81. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_instances.rb +56 -1
  82. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_reserved_instances.rb +1 -1
  83. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/describe_db_security_groups.rb +44 -2
  84. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/modify_db_instance.rb +26 -1
  85. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/reboot_db_instance.rb +17 -1
  86. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/rds/revoke_db_security_group_ingress.rb +27 -1
  87. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/change_message_visibility.rb +1 -1
  88. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/delete_message.rb +1 -1
  89. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/sqs/receive_message.rb +13 -14
  90. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/copy_object.rb +14 -6
  91. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/delete_object.rb +73 -2
  92. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket.rb +3 -2
  93. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket_object_versions.rb +95 -2
  94. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_bucket_versioning.rb +32 -0
  95. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object.rb +27 -1
  96. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object_http_url.rb +4 -3
  97. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/get_object_https_url.rb +4 -3
  98. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_bucket_versioning.rb +41 -0
  99. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_bucket_website.rb +17 -0
  100. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/requests/storage/put_object.rb +25 -9
  101. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/ses.rb +2 -7
  102. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/simpledb.rb +4 -17
  103. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/sns.rb +1 -14
  104. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/sqs.rb +5 -11
  105. data/lib/brightbox-cli/vendor/fog/lib/fog/aws/storage.rb +6 -22
  106. data/lib/brightbox-cli/vendor/fog/lib/fog/bin.rb +2 -0
  107. data/lib/brightbox-cli/vendor/fog/lib/fog/bin/aws.rb +9 -1
  108. data/lib/brightbox-cli/vendor/fog/lib/fog/bin/voxel.rb +1 -1
  109. data/lib/brightbox-cli/vendor/fog/lib/fog/brightbox/models/compute/server.rb +1 -0
  110. data/lib/brightbox-cli/vendor/fog/lib/fog/compute.rb +6 -0
  111. data/lib/brightbox-cli/vendor/fog/lib/fog/compute/models/server.rb +11 -0
  112. data/lib/brightbox-cli/vendor/fog/lib/fog/core.rb +0 -1
  113. data/lib/brightbox-cli/vendor/fog/lib/fog/core/connection.rb +0 -1
  114. data/lib/brightbox-cli/vendor/fog/lib/fog/core/errors.rb +5 -0
  115. data/lib/brightbox-cli/vendor/fog/lib/fog/core/scp.rb +18 -2
  116. data/lib/brightbox-cli/vendor/fog/lib/fog/core/wait_for.rb +1 -1
  117. data/lib/brightbox-cli/vendor/fog/lib/fog/dnsmadeeasy/dns.rb +1 -1
  118. data/lib/brightbox-cli/vendor/fog/lib/fog/dynect/models/dns/records.rb +2 -2
  119. data/lib/brightbox-cli/vendor/fog/lib/fog/dynect/requests/dns/get_node_list.rb +2 -1
  120. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/compute.rb +1 -1
  121. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_backup_internet_service.rb +1 -1
  122. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_internet_service.rb +2 -2
  123. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/add_node.rb +1 -1
  124. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/clone_vapp.rb +1 -1
  125. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_internet_service.rb +1 -1
  126. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_network.rb +1 -1
  127. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_network_ip.rb +1 -1
  128. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/configure_vapp.rb +1 -1
  129. data/lib/brightbox-cli/vendor/fog/lib/fog/ecloud/requests/compute/instantiate_vapp_template.rb +1 -1
  130. data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/compute.rb +7 -3
  131. data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/nodes.rb +1 -3
  132. data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/server.rb +93 -99
  133. data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/servers.rb +2 -1
  134. data/lib/brightbox-cli/vendor/fog/lib/fog/libvirt/models/compute/util.rb +1 -2
  135. data/lib/brightbox-cli/vendor/fog/lib/fog/providers.rb +2 -0
  136. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/dns.rb +10 -2
  137. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/load_balancers.rb +3 -0
  138. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/compute/flavor.rb +2 -0
  139. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/compute/server.rb +2 -2
  140. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/dns/callback.rb +3 -1
  141. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/dns/record.rb +4 -0
  142. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/load_balancers/load_balancer.rb +18 -8
  143. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/models/storage/directory.rb +5 -1
  144. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/compute/create_image.rb +1 -3
  145. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/load_balancers/delete_nodes.rb +1 -2
  146. data/lib/brightbox-cli/vendor/fog/lib/fog/rackspace/requests/load_balancers/list_load_balancers.rb +8 -2
  147. data/lib/brightbox-cli/vendor/fog/lib/fog/storm_on_demand/compute.rb +1 -1
  148. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/compute.rb +91 -30
  149. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalog.rb +1 -1
  150. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalog_item.rb +1 -1
  151. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/catalogs.rb +5 -8
  152. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/ip.rb +2 -2
  153. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/network.rb +9 -51
  154. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/networks.rb +21 -7
  155. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/server.rb +38 -58
  156. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/servers.rb +12 -18
  157. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/task.rb +1 -1
  158. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/tasks.rb +1 -3
  159. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vdc.rb +14 -29
  160. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vdcs.rb +6 -11
  161. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/clone_vapp.rb +1 -1
  162. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_network.rb +1 -1
  163. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_network_ip.rb +1 -1
  164. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_vapp.rb +1 -1
  165. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/configure_vm.rb +1 -1
  166. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/instantiate_vapp_template.rb +1 -1
  167. data/lib/brightbox-cli/vendor/fog/lib/fog/vcloud/requests/compute/login.rb +8 -4
  168. data/lib/brightbox-cli/vendor/fog/lib/fog/virtual_box/compute.rb +4 -0
  169. data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/compute.rb +1 -0
  170. data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/models/compute/server.rb +7 -1
  171. data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/requests/compute/list_virtual_machines.rb +86 -86
  172. data/lib/brightbox-cli/vendor/fog/lib/fog/vsphere/requests/compute/vm_clone.rb +43 -8
  173. data/lib/brightbox-cli/vendor/fog/lib/fog/zerigo/models/dns/record.rb +7 -5
  174. data/lib/brightbox-cli/vendor/fog/lib/fog/zerigo/requests/dns/update_host.rb +2 -2
  175. data/lib/brightbox-cli/vendor/fog/spec/ecloud/spec_helper.rb +1 -1
  176. data/lib/brightbox-cli/vendor/fog/tests/aws/models/elb/model_tests.rb +15 -6
  177. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/compute/instance_tests.rb +37 -0
  178. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/compute/security_group_tests.rb +6 -4
  179. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/helper.rb +33 -0
  180. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/listener_tests.rb +22 -4
  181. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/elb/policy_tests.rb +13 -0
  182. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/access_key_tests.rb +2 -7
  183. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/group_tests.rb +1 -4
  184. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/user_policy_tests.rb +4 -11
  185. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/iam/user_tests.rb +19 -12
  186. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/rds/helper.rb +38 -3
  187. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/rds/instance_tests.rb +3 -1
  188. data/lib/brightbox-cli/vendor/fog/tests/aws/requests/storage/bucket_tests.rb +66 -1
  189. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/account_tests.rb +3 -3
  190. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/api_client_tests.rb +6 -6
  191. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/cloud_ip_tests.rb +15 -9
  192. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/helper.rb +6 -2
  193. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/image_tests.rb +2 -2
  194. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/interface_tests.rb +1 -1
  195. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/load_balancer_tests.rb +9 -9
  196. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_group_tests.rb +8 -8
  197. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_tests.rb +17 -13
  198. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/server_type_tests.rb +2 -2
  199. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/user_tests.rb +3 -3
  200. data/lib/brightbox-cli/vendor/fog/tests/brightbox/requests/compute/zone_tests.rb +2 -2
  201. data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/helper.rb +87 -64
  202. data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/ip_tests.rb +1 -1
  203. data/lib/brightbox-cli/vendor/fog/tests/glesys/requests/compute/server_tests.rb +4 -4
  204. data/lib/brightbox-cli/vendor/fog/tests/helpers/formats_helper.rb +1 -1
  205. data/lib/brightbox-cli/vendor/fog/tests/helpers/mock_helper.rb +2 -0
  206. data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/dns/dns_tests.rb +4 -2
  207. data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/helper.rb +27 -11
  208. data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/load_balancer_tests.rb +4 -1
  209. data/lib/brightbox-cli/vendor/fog/tests/rackspace/requests/load_balancers/node_tests.rb +24 -25
  210. data/lib/brightbox-cli/vendor/fog/tests/slicehost/requests/compute/slice_tests.rb +2 -2
  211. data/lib/brightbox-cli/vendor/fog/tests/storm_on_demand/requests/compute/server_tests.rb +3 -3
  212. data/lib/brightbox-cli/vendor/fog/tests/vcloud/models/compute/servers_tests.rb +18 -90
  213. data/lib/brightbox-cli/vendor/fog/tests/vsphere/requests/compute/vm_clone_tests.rb +16 -4
  214. data/lib/brightbox-cli/vendor/fog/tests/vsphere/requests/compute/vm_power_on_tests.rb +1 -1
  215. data/lib/brightbox-cli/version.rb +1 -1
  216. data/spec/cloud_ips_spec.rb +1 -1
  217. data/spec/fixtures/vcr_cassettes/list_cloud_ip.yml +58 -26
  218. data/spec/fixtures/vcr_cassettes/server_show.yml +143 -102
  219. data/spec/servers_spec.rb +3 -2
  220. data/spec/spec_helper.rb +4 -0
  221. metadata +128 -213
  222. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/access_list_tests.rb +0 -12
  223. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/access_lists_tests.rb +0 -12
  224. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/load_balancer_tests.rb +0 -116
  225. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/load_balancers_tests.rb +0 -19
  226. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/node_tests.rb +0 -19
  227. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/nodes_tests.rb +0 -12
  228. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/virtual_ip_tests.rb +0 -16
  229. data/lib/brightbox-cli/vendor/fog/tests/rackspace/models/virtual_ips_tests.rb +0 -12
@@ -45,7 +45,7 @@ geemus says: "That should give you everything you need to get started, but let m
45
45
  * Find something you would like to work on. For suggestions look for the `easy`, `medium` and `hard` tags in the [issues](http://github.com/fog/fog/issues)
46
46
  * Fork the project and do your work in a topic branch.
47
47
  * Add shindo tests to prove your code works and run all the tests using `bundle exec rake`.
48
- * Rebase your branch against geemus/fog to make sure everything is up to date.
48
+ * Rebase your branch against fog/fog to make sure everything is up to date.
49
49
  * Commit your changes and send a pull request.
50
50
 
51
51
  ## Resources
@@ -35,8 +35,8 @@ First, create a connection with your new account:
35
35
  # create a connection
36
36
  connection = Fog::Storage.new({
37
37
  :provider => 'AWS',
38
- :aws_secret_access_key => YOUR_SECRET_ACCESS_KEY,
39
- :aws_access_key_id => YOUR_SECRET_ACCESS_KEY_ID
38
+ :aws_access_key_id => YOUR_SECRET_ACCESS_KEY_ID,
39
+ :aws_secret_access_key => YOUR_SECRET_ACCESS_KEY
40
40
  })
41
41
 
42
42
  # First, a place to contain the glorious details
@@ -131,8 +131,8 @@ Sign up <a href="http://gs-signup-redirect.appspot.com/">here</a> and get your c
131
131
 
132
132
  connection = Fog::Storage.new({
133
133
  :provider => 'Google',
134
- :google_storage_secret_access_key => YOUR_SECRET_ACCESS_KEY,
135
- :google_storage_access_key_id => YOUR_SECRET_ACCESS_KEY_ID
134
+ :google_storage_access_key_id => YOUR_SECRET_ACCESS_KEY_ID,
135
+ :google_storage_secret_access_key => YOUR_SECRET_ACCESS_KEY
136
136
  })
137
137
 
138
138
  ## Rackspace CloudFiles
@@ -7,7 +7,7 @@ require File.join(File.dirname(__FILE__), '..', 'tests', 'helper')
7
7
  Shindo.tests('compute examples', 'compute') do
8
8
 
9
9
  # iterate over all the providers
10
- Fog.providers.each do |provider|
10
+ Fog.providers.values.each do |provider|
11
11
 
12
12
  # FIXME: implement expected shared compute stuff for these providers as well
13
13
  next if ['Bluebox', 'Brightbox', 'Ecloud', 'GoGrid', 'Linode', 'NewServers', 'Ninefold', 'Slicehost', 'StormOnDemand', 'VirtualBox', 'Voxel'].include?(provider)
@@ -44,17 +44,29 @@ Shindo.tests('compute examples', 'compute') do
44
44
 
45
45
  # scp a file to a server
46
46
  lorem_path = File.join([File.dirname(__FILE__), '..', 'tests', 'lorem.txt'])
47
- tests("@server.scp('#{lorem_path}', 'lorem.txt')").succeeds do
48
- @server.scp(lorem_path, 'lorem.txt')
47
+ tests("@server.scp_upload('#{lorem_path}', 'lorem.txt')").succeeds do
48
+ @server.scp_upload(lorem_path, 'lorem.txt')
49
49
  end
50
50
 
51
+ # scp a file from a server
52
+ tests("@server.scp_download('lorem.txt', '/tmp/lorem.txt)").succeeds do
53
+ @server.scp_download('lorem.txt', '/tmp/lorem.txt')
54
+ end
55
+ File.delete('/tmp/lorem.txt')
56
+
51
57
  # scp a directory to a server
52
58
  Dir.mkdir('/tmp/lorem')
53
59
  file = ::File.new('/tmp/lorem/lorem.txt', 'w')
54
60
  file.write(File.read(lorem_path))
55
- lorem_dir = File.join([File.dirname(__FILE__), '..', 'tests'])
56
- tests("@server.scp('#{lorem_dir}', '/tmp/lorem', :recursive => true)").succeeds do
57
- @server.scp(lorem_dir, '/tmp/lorem', :recursive => true)
61
+ tests("@server.scp_upload('/tmp/lorem', '/tmp', :recursive => true)").succeeds do
62
+ @server.scp_upload('/tmp/lorem', '/tmp', :recursive => true)
63
+ end
64
+ File.delete('/tmp/lorem/lorem.txt')
65
+ Dir.rmdir('/tmp/lorem')
66
+
67
+ # scp a directory from a server
68
+ tests("@server.scp_download('/tmp/lorem', '/tmp', :recursive => true)").succeeds do
69
+ @server.scp_download('/tmp/lorem', '/tmp', :recursive => true)
58
70
  end
59
71
  File.delete('/tmp/lorem/lorem.txt')
60
72
  Dir.rmdir('/tmp/lorem')
@@ -7,7 +7,7 @@ require File.join(File.dirname(__FILE__), '..', 'tests', 'helper')
7
7
  Shindo.tests('dns examples', 'dns') do
8
8
 
9
9
  # iterate over all the providers
10
- Fog.providers.each do |provider|
10
+ Fog.providers.values.each do |provider|
11
11
 
12
12
  provider = eval(provider) # convert from string to object
13
13
 
@@ -7,7 +7,7 @@ require File.join(File.dirname(__FILE__), '..', 'tests', 'helper')
7
7
  Shindo.tests('storage examples', 'storage') do
8
8
 
9
9
  # iterate over all the providers
10
- Fog.providers.each do |provider|
10
+ Fog.providers.values.each do |provider|
11
11
 
12
12
  provider = eval(provider) # convert from string to object
13
13
 
@@ -6,8 +6,8 @@ Gem::Specification.new do |s|
6
6
  ## If your rubyforge_project name is different, then edit it and comment out
7
7
  ## the sub! line in the Rakefile
8
8
  s.name = 'fog'
9
- s.version = '1.1.1'
10
- s.date = '2011-11-11'
9
+ s.version = '1.1.2'
10
+ s.date = '2011-12-18'
11
11
  s.rubyforge_project = 'fog'
12
12
 
13
13
  ## Make sure your summary is short. The description may be as long
@@ -37,7 +37,7 @@ Gem::Specification.new do |s|
37
37
  ## List your runtime dependencies here. Runtime dependencies are those
38
38
  ## that are needed for an end user to actually USE your code.
39
39
  s.add_dependency('builder')
40
- s.add_dependency('excon', '~>0.7.4')
40
+ s.add_dependency('excon', '~>0.9.0')
41
41
  s.add_dependency('formatador', '~>0.2.0')
42
42
  s.add_dependency('multi_json', '~>1.0.3')
43
43
  s.add_dependency('mime-types')
@@ -52,6 +52,7 @@ Gem::Specification.new do |s|
52
52
  s.add_development_dependency('rake')
53
53
  s.add_development_dependency('rbvmomi')
54
54
  s.add_development_dependency('rdoc')
55
+ s.add_development_dependency('thor')
55
56
  s.add_development_dependency('rspec', '~>1.3.1')
56
57
  s.add_development_dependency('shindo', '~>0.3.4')
57
58
  s.add_development_dependency('virtualbox', '~>0.9.1')
@@ -3,7 +3,7 @@ require File.join(File.dirname(__FILE__), 'fog', 'core')
3
3
  module Fog
4
4
 
5
5
  unless const_defined?(:VERSION)
6
- VERSION = '1.1.1'
6
+ VERSION = '1.1.2'
7
7
  end
8
8
 
9
9
  end
@@ -10,6 +10,7 @@ module Fog
10
10
  service(:compute, 'aws/compute', 'Compute')
11
11
  service(:cloud_formation, 'aws/cloud_formation', 'CloudFormation')
12
12
  service(:cloud_watch, 'aws/cloud_watch', 'CloudWatch')
13
+ service(:dynamodb, 'aws/dynamodb', 'DynamoDB')
13
14
  service(:dns, 'aws/dns', 'DNS')
14
15
  service(:elasticache, 'aws/elasticache', 'Elasticache')
15
16
  service(:elb, 'aws/elb', 'ELB')
@@ -20,6 +21,7 @@ module Fog
20
21
  service(:simpledb, 'aws/simpledb', 'SimpleDB')
21
22
  service(:sns, 'aws/sns', 'SNS')
22
23
  service(:sqs, 'aws/sqs', 'SQS')
24
+ service(:sts, 'aws/sts', 'STS')
23
25
  service(:storage, 'aws/storage', 'Storage')
24
26
 
25
27
  def self.indexed_param(key, values)
@@ -39,7 +41,7 @@ module Fog
39
41
  end
40
42
  params
41
43
  end
42
-
44
+
43
45
  def self.serialize_keys(key, value, options = {})
44
46
  case value
45
47
  when Hash
@@ -85,6 +87,10 @@ module Fog
85
87
  'Version' => options[:version]
86
88
  })
87
89
 
90
+ params.merge!({
91
+ 'SecurityToken' => options[:aws_session_token]
92
+ }) if options[:aws_session_token]
93
+
88
94
  body = ''
89
95
  for key in params.keys.sort
90
96
  unless (value = params[key]).nil?
@@ -218,6 +224,15 @@ module Fog
218
224
  def self.volume_id
219
225
  "vol-#{Fog::Mock.random_hex(8)}"
220
226
  end
227
+
228
+ def self.key_id(length=21)
229
+ #Probably close enough
230
+ Fog::Mock.random_selection('ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789',length)
231
+ end
232
+
233
+ def self.rds_address(db_name,region)
234
+ "#{db_name}.#{Fog::Mock.random_letters(rand(12) + 4)}.#{region}.rds.amazonaws.com"
235
+ end
221
236
  end
222
237
  end
223
238
  end
@@ -77,22 +77,7 @@ module Fog
77
77
 
78
78
  @connection_options = options[:connection_options] || {}
79
79
  options[:region] ||= 'us-east-1'
80
- @host = options[:host] || case options[:region]
81
- when 'ap-northeast-1'
82
- 'autoscaling.ap-northeast-1.amazonaws.com'
83
- when 'ap-southeast-1'
84
- 'autoscaling.ap-southeast-1.amazonaws.com'
85
- when 'eu-west-1'
86
- 'autoscaling.eu-west-1.amazonaws.com'
87
- when 'us-east-1'
88
- 'autoscaling.us-east-1.amazonaws.com'
89
- when 'us-west-1'
90
- 'autoscaling.us-west-1.amazonaws.com'
91
- when 'us-west-2'
92
- 'autoscaling.us-west-2.amazonaws.com'
93
- else
94
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
95
- end
80
+ @host = options[:host] || "autoscaling.#{options[:region]}.amazonaws.com"
96
81
  @path = options[:path] || '/'
97
82
  @port = options[:port] || 443
98
83
  @persistent = options[:persistent] || false
@@ -206,7 +191,7 @@ module Fog
206
191
 
207
192
  @region = options[:region] || 'us-east-1'
208
193
 
209
- unless ['ap-northeast-1', 'ap-southeast-1', 'eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2'].include?(@region)
194
+ unless ['ap-northeast-1', 'ap-southeast-1', 'eu-west-1', 'sa-east-1', 'us-east-1', 'us-west-1', 'us-west-2'].include?(@region)
210
195
  raise ArgumentError, "Unknown region: #{@region.inspect}"
211
196
  end
212
197
 
@@ -54,22 +54,7 @@ module Fog
54
54
 
55
55
  @connection_options = options[:connection_options] || {}
56
56
  options[:region] ||= 'us-east-1'
57
- @host = options[:host] || case options[:region]
58
- when 'ap-northeast-1'
59
- 'cloudformation.ap-northeast-1.amazonaws.com'
60
- when 'ap-southeast-1'
61
- 'cloudformation.ap-southeast-1.amazonaws.com'
62
- when 'eu-west-1'
63
- 'cloudformation.eu-west-1.amazonaws.com'
64
- when 'us-east-1'
65
- 'cloudformation.us-east-1.amazonaws.com'
66
- when 'us-west-1'
67
- 'cloudformation.us-west-1.amazonaws.com'
68
- when 'us-west-2'
69
- 'cloudformation.us-west-2.amazonaws.com'
70
- else
71
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
72
- end
57
+ @host = options[:host] || "cloudformation.#{options[:region]}.amazonaws.com"
73
58
  @path = options[:path] || '/'
74
59
  @persistent = options[:persistent] || false
75
60
  @port = options[:port] || 443
@@ -57,7 +57,7 @@ module Fog
57
57
  #
58
58
  # ==== Parameters
59
59
  # * options<~Hash> - config arguments for connection. Defaults to {}.
60
- # * region<~String> - optional region to use, in ['eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2', 'ap-southeast-1', 'ap-northeast-1']
60
+ # * region<~String> - optional region to use. For instance, 'eu-west-1', 'us-east-1', etc.
61
61
  #
62
62
  # ==== Returns
63
63
  # * CloudWatch object with connection to AWS.
@@ -68,22 +68,7 @@ module Fog
68
68
 
69
69
  @connection_options = options[:connection_options] || {}
70
70
  options[:region] ||= 'us-east-1'
71
- @host = options[:host] || case options[:region]
72
- when 'ap-northeast-1'
73
- 'monitoring.ap-northeast-1.amazonaws.com'
74
- when 'ap-southeast-1'
75
- 'monitoring.ap-southeast-1.amazonaws.com'
76
- when 'eu-west-1'
77
- 'monitoring.eu-west-1.amazonaws.com'
78
- when 'us-east-1'
79
- 'monitoring.us-east-1.amazonaws.com'
80
- when 'us-west-1'
81
- 'monitoring.us-west-1.amazonaws.com'
82
- when 'us-west-2'
83
- 'monitoring.us-west-2.amazonaws.com'
84
- else
85
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
86
- end
71
+ @host = options[:host] || "monitoring.#{options[:region]}.amazonaws.com"
87
72
  @path = options[:path] || '/'
88
73
  @persistent = options[:persistent] || false
89
74
  @port = options[:port] || 443
@@ -6,7 +6,7 @@ module Fog
6
6
  class AWS < Fog::Service
7
7
 
8
8
  requires :aws_access_key_id, :aws_secret_access_key
9
- recognizes :endpoint, :region, :host, :path, :port, :scheme, :persistent
9
+ recognizes :endpoint, :region, :host, :path, :port, :scheme, :persistent, :aws_session_token
10
10
 
11
11
  model_path 'fog/aws/models/compute'
12
12
  model :address
@@ -57,6 +57,7 @@ module Fog
57
57
  request :describe_images
58
58
  request :describe_instances
59
59
  request :describe_reserved_instances
60
+ request :describe_instance_status
60
61
  request :describe_key_pairs
61
62
  request :describe_placement_groups
62
63
  request :describe_regions
@@ -170,7 +171,7 @@ module Fog
170
171
 
171
172
  @region = options[:region] || 'us-east-1'
172
173
 
173
- unless ['ap-northeast-1', 'ap-southeast-1', 'eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2'].include?(@region)
174
+ unless ['ap-northeast-1', 'ap-southeast-1', 'eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2', 'sa-east-1'].include?(@region)
174
175
  raise ArgumentError, "Unknown region: #{@region.inspect}"
175
176
  end
176
177
  end
@@ -247,8 +248,9 @@ module Fog
247
248
  #
248
249
  # ==== Parameters
249
250
  # * options<~Hash> - config arguments for connection. Defaults to {}.
250
- # * region<~String> - optional region to use, in
251
- # ['eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2', 'ap-northeast-1', 'ap-southeast-1']
251
+ # * region<~String> - optional region to use. For instance,
252
+ # 'eu-west-1', 'us-east-1', and etc.
253
+ # * aws_session_token<~String> - when using Session Tokens or Federated Users, a session_token must be presented
252
254
  #
253
255
  # ==== Returns
254
256
  # * EC2 object with connection to aws.
@@ -257,6 +259,7 @@ module Fog
257
259
 
258
260
  @aws_access_key_id = options[:aws_access_key_id]
259
261
  @aws_secret_access_key = options[:aws_secret_access_key]
262
+ @aws_session_token = options[:aws_session_token]
260
263
  @connection_options = options[:connection_options] || {}
261
264
  @hmac = Fog::HMAC.new('sha256', @aws_secret_access_key)
262
265
  @region = options[:region] ||= 'us-east-1'
@@ -268,22 +271,7 @@ module Fog
268
271
  @port = endpoint.port
269
272
  @scheme = endpoint.scheme
270
273
  else
271
- @host = options[:host] || case options[:region]
272
- when 'ap-northeast-1'
273
- 'ec2.ap-northeast-1.amazonaws.com'
274
- when 'ap-southeast-1'
275
- 'ec2.ap-southeast-1.amazonaws.com'
276
- when 'eu-west-1'
277
- 'ec2.eu-west-1.amazonaws.com'
278
- when 'us-east-1'
279
- 'ec2.us-east-1.amazonaws.com'
280
- when 'us-west-1'
281
- 'ec2.us-west-1.amazonaws.com'
282
- when 'us-west-2'
283
- 'ec2.us-west-2.amazonaws.com'
284
- else
285
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
286
- end
274
+ @host = options[:host] || "ec2.#{options[:region]}.amazonaws.com"
287
275
  @path = options[:path] || '/'
288
276
  @persistent = options[:persistent] || false
289
277
  @port = options[:port] || 443
@@ -306,11 +294,12 @@ module Fog
306
294
  params,
307
295
  {
308
296
  :aws_access_key_id => @aws_access_key_id,
297
+ :aws_session_token => @aws_session_token,
309
298
  :hmac => @hmac,
310
299
  :host => @host,
311
300
  :path => @path,
312
301
  :port => @port,
313
- :version => '2011-05-15'
302
+ :version => '2011-12-15'
314
303
  }
315
304
  )
316
305
 
@@ -54,13 +54,7 @@ module Fog
54
54
  @hmac = Fog::HMAC.new('sha256', @aws_secret_access_key)
55
55
 
56
56
  options[:region] ||= 'us-east-1'
57
- @host = options[:host] || case options[:region]
58
- when 'us-east-1'
59
- 'elasticache.us-east-1.amazonaws.com'
60
- #TODO: Support other regions
61
- else
62
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
63
- end
57
+ @host = options[:host] || "elasticache.#{options[:region]}.amazonaws.com"
64
58
  @path = options[:path] || '/'
65
59
  @port = options[:port] || 443
66
60
  @scheme = options[:scheme] || 'https'
@@ -4,9 +4,15 @@ module Fog
4
4
  module AWS
5
5
  class ELB < Fog::Service
6
6
 
7
- class IdentifierTaken < Fog::Errors::Error; end
8
- class InvalidInstance < Fog::Errors::Error; end
9
- class Throttled < Fog::Errors::Error; end
7
+ class DuplicatePolicyName < Fog::Errors::Error; end
8
+ class IdentifierTaken < Fog::Errors::Error; end
9
+ class InvalidInstance < Fog::Errors::Error; end
10
+ class InvalidConfigurationRequest < Fog::Errors::Error; end
11
+ class PolicyNotFound < Fog::Errors::Error; end
12
+ class PolicyTypeNotFound < Fog::Errors::Error; end
13
+ class Throttled < Fog::Errors::Error; end
14
+ class TooManyPolicies < Fog::Errors::Error; end
15
+ class ValidationError < Fog::Errors::Error; end
10
16
 
11
17
  requires :aws_access_key_id, :aws_secret_access_key
12
18
  recognizes :region, :host, :path, :port, :scheme, :persistent
@@ -17,12 +23,15 @@ module Fog
17
23
  request :create_lb_cookie_stickiness_policy
18
24
  request :create_load_balancer
19
25
  request :create_load_balancer_listeners
26
+ request :create_load_balancer_policy
20
27
  request :delete_load_balancer
21
28
  request :delete_load_balancer_listeners
22
29
  request :delete_load_balancer_policy
23
30
  request :deregister_instances_from_load_balancer
24
31
  request :describe_instance_health
25
32
  request :describe_load_balancers
33
+ request :describe_load_balancer_policies
34
+ request :describe_load_balancer_policy_types
26
35
  request :disable_availability_zones_for_load_balancer
27
36
  request :enable_availability_zones_for_load_balancer
28
37
  request :register_instances_with_load_balancer
@@ -39,13 +48,16 @@ module Fog
39
48
 
40
49
  class Mock
41
50
 
51
+ require 'fog/aws/elb/policy_types'
52
+
42
53
  def self.data
43
54
  @data ||= Hash.new do |hash, region|
44
55
  owner_id = Fog::AWS::Mock.owner_id
45
56
  hash[region] = Hash.new do |region_hash, key|
46
57
  region_hash[key] = {
47
58
  :owner_id => owner_id,
48
- :load_balancers => {}
59
+ :load_balancers => {},
60
+ :policy_types => Fog::AWS::ELB::Mock::POLICY_TYPES
49
61
  }
50
62
  end
51
63
  end
@@ -94,7 +106,7 @@ module Fog
94
106
  #
95
107
  # ==== Parameters
96
108
  # * options<~Hash> - config arguments for connection. Defaults to {}.
97
- # * region<~String> - optional region to use, in ['eu-west-1', 'us-east-1', 'us-west-1', 'us-west-2', 'ap-northeast-1', 'ap-southeast-1']
109
+ # * region<~String> - optional region to use. For instance, 'eu-west-1', 'us-east-1', etc.
98
110
  #
99
111
  # ==== Returns
100
112
  # * ELB object with connection to AWS.
@@ -107,22 +119,7 @@ module Fog
107
119
  @hmac = Fog::HMAC.new('sha256', @aws_secret_access_key)
108
120
 
109
121
  options[:region] ||= 'us-east-1'
110
- @host = options[:host] || case options[:region]
111
- when 'ap-northeast-1'
112
- 'elasticloadbalancing.ap-northeast-1.amazonaws.com'
113
- when 'ap-southeast-1'
114
- 'elasticloadbalancing.ap-southeast-1.amazonaws.com'
115
- when 'eu-west-1'
116
- 'elasticloadbalancing.eu-west-1.amazonaws.com'
117
- when 'us-east-1'
118
- 'elasticloadbalancing.us-east-1.amazonaws.com'
119
- when 'us-west-1'
120
- 'elasticloadbalancing.us-west-1.amazonaws.com'
121
- when 'us-west-2'
122
- 'elasticloadbalancing.us-west-2.amazonaws.com'
123
- else
124
- raise ArgumentError, "Unknown region: #{options[:region].inspect}"
125
- end
122
+ @host = options[:host] || "elasticloadbalancing.#{options[:region]}.amazonaws.com"
126
123
  @path = options[:path] || '/'
127
124
  @persistent = options[:persistent] || false
128
125
  @port = options[:port] || 443
@@ -148,7 +145,7 @@ module Fog
148
145
  :host => @host,
149
146
  :path => @path,
150
147
  :port => @port,
151
- :version => '2011-04-05'
148
+ :version => '2011-11-15'
152
149
  }
153
150
  )
154
151
 
@@ -166,14 +163,27 @@ module Fog
166
163
  case match[1]
167
164
  when 'CertificateNotFound'
168
165
  raise Fog::AWS::IAM::NotFound.slurp(error, match[2])
169
- when 'LoadBalancerNotFound'
170
- raise Fog::AWS::ELB::NotFound.slurp(error, match[2])
171
166
  when 'DuplicateLoadBalancerName'
172
167
  raise Fog::AWS::ELB::IdentifierTaken.slurp(error, match[2])
168
+ when 'DuplicatePolicyName'
169
+ raise Fog::AWS::ELB::DuplicatePolicyName.slurp(error, match[2])
173
170
  when 'InvalidInstance'
174
171
  raise Fog::AWS::ELB::InvalidInstance.slurp(error, match[2])
172
+ when 'InvalidConfigurationRequest'
173
+ # when do they fucking use this shit?
174
+ raise Fog::AWS::ELB::InvalidConfigurationRequest.slurp(error, match[2])
175
+ when 'LoadBalancerNotFound'
176
+ raise Fog::AWS::ELB::NotFound.slurp(error, match[2])
177
+ when 'PolicyNotFound'
178
+ raise Fog::AWS::ELB::PolicyNotFound.slurp(error, match[2])
179
+ when 'PolicyTypeNotFound'
180
+ raise Fog::AWS::ELB::PolicyTypeNotFound.slurp(error, match[2])
175
181
  when 'Throttling'
176
182
  raise Fog::AWS::ELB::Throttled.slurp(error, match[2])
183
+ when 'TooManyPolicies'
184
+ raise Fog::AWS::ELB::TooManyPolicies.slurp(error, match[2])
185
+ when 'ValidationError'
186
+ raise Fog::AWS::ELB::ValidationError.slurp(error, match[2])
177
187
  else
178
188
  raise
179
189
  end