fog 1.42.1 → 2.0.0.pre.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2444) hide show
  1. checksums.yaml +5 -5
  2. data/.travis.yml +4 -16
  3. data/CHANGELOG.md +0 -499
  4. data/CONTRIBUTING.md +1 -1
  5. data/CONTRIBUTORS.md +1 -3
  6. data/Gemfile +1 -1
  7. data/LICENSE.md +1 -1
  8. data/README.md +12 -24
  9. data/Rakefile +20 -23
  10. data/fog.gemspec +11 -35
  11. data/gemfiles/Gemfile-edge +1 -1
  12. data/lib/fog.rb +2 -1
  13. data/lib/fog/bin.rb +2 -1
  14. data/lib/fog/bin/digitalocean.rb +29 -0
  15. data/lib/fog/bin/dnsimple.rb +29 -0
  16. data/lib/fog/bin/hp.rb +60 -0
  17. data/lib/fog/bin/internet_archive.rb +32 -0
  18. data/lib/fog/bin/joyent.rb +33 -0
  19. data/lib/fog/bin/ninefold.rb +34 -0
  20. data/lib/fog/bin/ovirt.rb +28 -0
  21. data/lib/fog/bin/vsphere.rb +28 -0
  22. data/lib/fog/cloudsigma/compute.rb +0 -9
  23. data/lib/fog/cloudsigma/models/server.rb +0 -5
  24. data/lib/fog/cloudsigma/models/volume.rb +0 -15
  25. data/lib/fog/cloudsigma/requests/stop_server.rb +4 -5
  26. data/lib/fog/cloudstack/core.rb +0 -2
  27. data/lib/fog/digitalocean.rb +1 -0
  28. data/lib/fog/digitalocean/CHANGELOG.md +6 -0
  29. data/lib/fog/digitalocean/compute.rb +130 -0
  30. data/lib/fog/digitalocean/core.rb +9 -0
  31. data/lib/fog/digitalocean/examples/getting_started.md +148 -0
  32. data/lib/fog/digitalocean/models/compute/flavor.rb +12 -0
  33. data/lib/fog/digitalocean/models/compute/flavors.rb +22 -0
  34. data/lib/fog/digitalocean/models/compute/image.rb +13 -0
  35. data/lib/fog/digitalocean/models/compute/images.rb +22 -0
  36. data/lib/fog/digitalocean/models/compute/region.rb +12 -0
  37. data/lib/fog/digitalocean/models/compute/regions.rb +22 -0
  38. data/lib/fog/digitalocean/models/compute/server.rb +203 -0
  39. data/lib/fog/digitalocean/models/compute/servers.rb +95 -0
  40. data/lib/fog/digitalocean/models/compute/ssh_key.rb +26 -0
  41. data/lib/fog/digitalocean/models/compute/ssh_keys.rb +25 -0
  42. data/lib/fog/digitalocean/requests/compute/create_server.rb +77 -0
  43. data/lib/fog/digitalocean/requests/compute/create_ssh_key.rb +34 -0
  44. data/lib/fog/digitalocean/requests/compute/destroy_server.rb +35 -0
  45. data/lib/fog/digitalocean/requests/compute/destroy_ssh_key.rb +33 -0
  46. data/lib/fog/digitalocean/requests/compute/get_server_details.rb +31 -0
  47. data/lib/fog/digitalocean/requests/compute/get_ssh_key.rb +35 -0
  48. data/lib/fog/digitalocean/requests/compute/list_flavors.rb +34 -0
  49. data/lib/fog/digitalocean/requests/compute/list_images.rb +45 -0
  50. data/lib/fog/digitalocean/requests/compute/list_regions.rb +34 -0
  51. data/lib/fog/digitalocean/requests/compute/list_servers.rb +27 -0
  52. data/lib/fog/digitalocean/requests/compute/list_ssh_keys.rb +27 -0
  53. data/lib/fog/digitalocean/requests/compute/power_cycle_server.rb +29 -0
  54. data/lib/fog/digitalocean/requests/compute/power_off_server.rb +29 -0
  55. data/lib/fog/digitalocean/requests/compute/power_on_server.rb +29 -0
  56. data/lib/fog/digitalocean/requests/compute/reboot_server.rb +29 -0
  57. data/lib/fog/digitalocean/requests/compute/shutdown_server.rb +32 -0
  58. data/lib/fog/dnsimple.rb +1 -0
  59. data/lib/fog/dnsimple/core.rb +10 -0
  60. data/lib/fog/dnsimple/dns.rb +112 -0
  61. data/lib/fog/dnsimple/models/dns/record.rb +63 -0
  62. data/lib/fog/dnsimple/models/dns/records.rb +34 -0
  63. data/lib/fog/dnsimple/models/dns/zone.rb +46 -0
  64. data/lib/fog/dnsimple/models/dns/zones.rb +25 -0
  65. data/lib/fog/dnsimple/requests/dns/create_domain.rb +62 -0
  66. data/lib/fog/dnsimple/requests/dns/create_record.rb +67 -0
  67. data/lib/fog/dnsimple/requests/dns/delete_domain.rb +35 -0
  68. data/lib/fog/dnsimple/requests/dns/delete_record.rb +30 -0
  69. data/lib/fog/dnsimple/requests/dns/get_domain.rb +39 -0
  70. data/lib/fog/dnsimple/requests/dns/get_record.rb +49 -0
  71. data/lib/fog/dnsimple/requests/dns/list_domains.rb +34 -0
  72. data/lib/fog/dnsimple/requests/dns/list_records.rb +34 -0
  73. data/lib/fog/dnsimple/requests/dns/update_record.rb +53 -0
  74. data/lib/fog/fogdocker/requests/compute/container_action.rb +2 -2
  75. data/lib/fog/glesys/models/compute/server.rb +1 -0
  76. data/lib/fog/hp.rb +9 -0
  77. data/lib/fog/hp/CHANGELOG.hp +156 -0
  78. data/lib/fog/hp/README.md +57 -0
  79. data/lib/fog/hp/articles/auth_caching.md +23 -0
  80. data/lib/fog/hp/block_storage.rb +170 -0
  81. data/lib/fog/hp/block_storage_v2.rb +159 -0
  82. data/lib/fog/hp/cdn.rb +154 -0
  83. data/lib/fog/hp/compute.rb +252 -0
  84. data/lib/fog/hp/compute_v2.rb +306 -0
  85. data/lib/fog/hp/core.rb +353 -0
  86. data/lib/fog/hp/dns.rb +130 -0
  87. data/lib/fog/hp/docs/connect.md +152 -0
  88. data/lib/fog/hp/docs/install.md +133 -0
  89. data/lib/fog/hp/examples/block_storage.md +296 -0
  90. data/lib/fog/hp/examples/block_storage_v2.md +446 -0
  91. data/lib/fog/hp/examples/cdn.md +54 -0
  92. data/lib/fog/hp/examples/compute.md +794 -0
  93. data/lib/fog/hp/examples/compute_v2.md +851 -0
  94. data/lib/fog/hp/examples/getting_started_examples.md +30 -0
  95. data/lib/fog/hp/examples/networking.md +472 -0
  96. data/lib/fog/hp/examples/object_storage.md +387 -0
  97. data/lib/fog/hp/lb.rb +163 -0
  98. data/lib/fog/hp/models/block_storage/bootable_volumes.rb +24 -0
  99. data/lib/fog/hp/models/block_storage/snapshot.rb +52 -0
  100. data/lib/fog/hp/models/block_storage/snapshots.rb +25 -0
  101. data/lib/fog/hp/models/block_storage/volume.rb +98 -0
  102. data/lib/fog/hp/models/block_storage/volumes.rb +24 -0
  103. data/lib/fog/hp/models/block_storage_v2/snapshot.rb +72 -0
  104. data/lib/fog/hp/models/block_storage_v2/snapshots.rb +39 -0
  105. data/lib/fog/hp/models/block_storage_v2/volume.rb +135 -0
  106. data/lib/fog/hp/models/block_storage_v2/volume_backup.rb +54 -0
  107. data/lib/fog/hp/models/block_storage_v2/volume_backups.rb +38 -0
  108. data/lib/fog/hp/models/block_storage_v2/volumes.rb +38 -0
  109. data/lib/fog/hp/models/compute/address.rb +66 -0
  110. data/lib/fog/hp/models/compute/addresses.rb +25 -0
  111. data/lib/fog/hp/models/compute/flavor.rb +20 -0
  112. data/lib/fog/hp/models/compute/flavors.rb +24 -0
  113. data/lib/fog/hp/models/compute/image.rb +72 -0
  114. data/lib/fog/hp/models/compute/images.rb +25 -0
  115. data/lib/fog/hp/models/compute/key_pair.rb +51 -0
  116. data/lib/fog/hp/models/compute/key_pairs.rb +28 -0
  117. data/lib/fog/hp/models/compute/meta.rb +27 -0
  118. data/lib/fog/hp/models/compute/metadata.rb +74 -0
  119. data/lib/fog/hp/models/compute/security_group.rb +48 -0
  120. data/lib/fog/hp/models/compute/security_groups.rb +26 -0
  121. data/lib/fog/hp/models/compute/server.rb +293 -0
  122. data/lib/fog/hp/models/compute/servers.rb +32 -0
  123. data/lib/fog/hp/models/compute_v2/address.rb +66 -0
  124. data/lib/fog/hp/models/compute_v2/addresses.rb +25 -0
  125. data/lib/fog/hp/models/compute_v2/availability_zone.rb +18 -0
  126. data/lib/fog/hp/models/compute_v2/availability_zones.rb +25 -0
  127. data/lib/fog/hp/models/compute_v2/flavor.rb +18 -0
  128. data/lib/fog/hp/models/compute_v2/flavors.rb +38 -0
  129. data/lib/fog/hp/models/compute_v2/image.rb +82 -0
  130. data/lib/fog/hp/models/compute_v2/images.rb +39 -0
  131. data/lib/fog/hp/models/compute_v2/key_pair.rb +51 -0
  132. data/lib/fog/hp/models/compute_v2/key_pairs.rb +28 -0
  133. data/lib/fog/hp/models/compute_v2/meta.rb +27 -0
  134. data/lib/fog/hp/models/compute_v2/meta_parent.rb +31 -0
  135. data/lib/fog/hp/models/compute_v2/metadata.rb +74 -0
  136. data/lib/fog/hp/models/compute_v2/server.rb +334 -0
  137. data/lib/fog/hp/models/compute_v2/servers.rb +52 -0
  138. data/lib/fog/hp/models/compute_v2/volume_attachment.rb +41 -0
  139. data/lib/fog/hp/models/compute_v2/volume_attachments.rb +29 -0
  140. data/lib/fog/hp/models/dns/domain.rb +53 -0
  141. data/lib/fog/hp/models/dns/domains.rb +25 -0
  142. data/lib/fog/hp/models/dns/record.rb +57 -0
  143. data/lib/fog/hp/models/dns/records.rb +29 -0
  144. data/lib/fog/hp/models/lb/algorithm.rb +23 -0
  145. data/lib/fog/hp/models/lb/algorithms.rb +25 -0
  146. data/lib/fog/hp/models/lb/load_balancer.rb +82 -0
  147. data/lib/fog/hp/models/lb/load_balancers.rb +25 -0
  148. data/lib/fog/hp/models/lb/node.rb +51 -0
  149. data/lib/fog/hp/models/lb/nodes.rb +28 -0
  150. data/lib/fog/hp/models/lb/protocol.rb +24 -0
  151. data/lib/fog/hp/models/lb/protocols.rb +25 -0
  152. data/lib/fog/hp/models/lb/virtual_ip.rb +33 -0
  153. data/lib/fog/hp/models/lb/virtual_ips.rb +31 -0
  154. data/lib/fog/hp/models/meta_parent.rb +31 -0
  155. data/lib/fog/hp/models/network/floating_ip.rb +43 -0
  156. data/lib/fog/hp/models/network/floating_ips.rb +33 -0
  157. data/lib/fog/hp/models/network/network.rb +54 -0
  158. data/lib/fog/hp/models/network/networks.rb +33 -0
  159. data/lib/fog/hp/models/network/port.rb +51 -0
  160. data/lib/fog/hp/models/network/ports.rb +33 -0
  161. data/lib/fog/hp/models/network/router.rb +64 -0
  162. data/lib/fog/hp/models/network/routers.rb +33 -0
  163. data/lib/fog/hp/models/network/security_group.rb +28 -0
  164. data/lib/fog/hp/models/network/security_group_rule.rb +33 -0
  165. data/lib/fog/hp/models/network/security_group_rules.rb +33 -0
  166. data/lib/fog/hp/models/network/security_groups.rb +33 -0
  167. data/lib/fog/hp/models/network/subnet.rb +47 -0
  168. data/lib/fog/hp/models/network/subnets.rb +33 -0
  169. data/lib/fog/hp/models/storage/directories.rb +71 -0
  170. data/lib/fog/hp/models/storage/directory.rb +305 -0
  171. data/lib/fog/hp/models/storage/file.rb +105 -0
  172. data/lib/fog/hp/models/storage/files.rb +129 -0
  173. data/lib/fog/hp/models/storage/meta.rb +27 -0
  174. data/lib/fog/hp/models/storage/meta_parent.rb +21 -0
  175. data/lib/fog/hp/models/storage/metadata.rb +77 -0
  176. data/lib/fog/hp/models/storage/shared_directories.rb +51 -0
  177. data/lib/fog/hp/models/storage/shared_directory.rb +36 -0
  178. data/lib/fog/hp/models/storage/shared_file.rb +64 -0
  179. data/lib/fog/hp/models/storage/shared_files.rb +60 -0
  180. data/lib/fog/hp/network.rb +200 -0
  181. data/lib/fog/hp/requests/block_storage/create_snapshot.rb +72 -0
  182. data/lib/fog/hp/requests/block_storage/create_volume.rb +83 -0
  183. data/lib/fog/hp/requests/block_storage/delete_snapshot.rb +34 -0
  184. data/lib/fog/hp/requests/block_storage/delete_volume.rb +34 -0
  185. data/lib/fog/hp/requests/block_storage/get_bootable_volume_details.rb +54 -0
  186. data/lib/fog/hp/requests/block_storage/get_snapshot_details.rb +49 -0
  187. data/lib/fog/hp/requests/block_storage/get_volume_details.rb +53 -0
  188. data/lib/fog/hp/requests/block_storage/list_bootable_volumes.rb +49 -0
  189. data/lib/fog/hp/requests/block_storage/list_snapshots.rb +44 -0
  190. data/lib/fog/hp/requests/block_storage/list_volumes.rb +48 -0
  191. data/lib/fog/hp/requests/block_storage_v2/create_snapshot.rb +72 -0
  192. data/lib/fog/hp/requests/block_storage_v2/create_volume.rb +86 -0
  193. data/lib/fog/hp/requests/block_storage_v2/create_volume_backup.rb +79 -0
  194. data/lib/fog/hp/requests/block_storage_v2/delete_snapshot.rb +34 -0
  195. data/lib/fog/hp/requests/block_storage_v2/delete_volume.rb +34 -0
  196. data/lib/fog/hp/requests/block_storage_v2/delete_volume_backup.rb +34 -0
  197. data/lib/fog/hp/requests/block_storage_v2/get_snapshot_details.rb +49 -0
  198. data/lib/fog/hp/requests/block_storage_v2/get_volume_backup_details.rb +50 -0
  199. data/lib/fog/hp/requests/block_storage_v2/get_volume_details.rb +53 -0
  200. data/lib/fog/hp/requests/block_storage_v2/list_snapshots.rb +53 -0
  201. data/lib/fog/hp/requests/block_storage_v2/list_snapshots_detail.rb +50 -0
  202. data/lib/fog/hp/requests/block_storage_v2/list_volume_backups.rb +48 -0
  203. data/lib/fog/hp/requests/block_storage_v2/list_volume_backups_detail.rb +54 -0
  204. data/lib/fog/hp/requests/block_storage_v2/list_volumes.rb +57 -0
  205. data/lib/fog/hp/requests/block_storage_v2/list_volumes_detail.rb +55 -0
  206. data/lib/fog/hp/requests/block_storage_v2/restore_volume_backup.rb +93 -0
  207. data/lib/fog/hp/requests/block_storage_v2/update_snapshot.rb +64 -0
  208. data/lib/fog/hp/requests/block_storage_v2/update_volume.rb +66 -0
  209. data/lib/fog/hp/requests/cdn/delete_container.rb +35 -0
  210. data/lib/fog/hp/requests/cdn/get_containers.rb +39 -0
  211. data/lib/fog/hp/requests/cdn/head_container.rb +47 -0
  212. data/lib/fog/hp/requests/cdn/post_container.rb +49 -0
  213. data/lib/fog/hp/requests/cdn/put_container.rb +50 -0
  214. data/lib/fog/hp/requests/compute/allocate_address.rb +44 -0
  215. data/lib/fog/hp/requests/compute/associate_address.rb +38 -0
  216. data/lib/fog/hp/requests/compute/attach_volume.rb +74 -0
  217. data/lib/fog/hp/requests/compute/change_password_server.rb +29 -0
  218. data/lib/fog/hp/requests/compute/confirm_resized_server.rb +30 -0
  219. data/lib/fog/hp/requests/compute/create_image.rb +55 -0
  220. data/lib/fog/hp/requests/compute/create_key_pair.rb +76 -0
  221. data/lib/fog/hp/requests/compute/create_persistent_server.rb +163 -0
  222. data/lib/fog/hp/requests/compute/create_security_group.rb +78 -0
  223. data/lib/fog/hp/requests/compute/create_security_group_rule.rb +70 -0
  224. data/lib/fog/hp/requests/compute/create_server.rb +142 -0
  225. data/lib/fog/hp/requests/compute/delete_image.rb +40 -0
  226. data/lib/fog/hp/requests/compute/delete_key_pair.rb +35 -0
  227. data/lib/fog/hp/requests/compute/delete_meta.rb +50 -0
  228. data/lib/fog/hp/requests/compute/delete_security_group.rb +37 -0
  229. data/lib/fog/hp/requests/compute/delete_security_group_rule.rb +44 -0
  230. data/lib/fog/hp/requests/compute/delete_server.rb +39 -0
  231. data/lib/fog/hp/requests/compute/detach_volume.rb +43 -0
  232. data/lib/fog/hp/requests/compute/disassociate_address.rb +35 -0
  233. data/lib/fog/hp/requests/compute/get_address.rb +41 -0
  234. data/lib/fog/hp/requests/compute/get_console_output.rb +37 -0
  235. data/lib/fog/hp/requests/compute/get_flavor_details.rb +47 -0
  236. data/lib/fog/hp/requests/compute/get_image_details.rb +38 -0
  237. data/lib/fog/hp/requests/compute/get_meta.rb +52 -0
  238. data/lib/fog/hp/requests/compute/get_security_group.rb +53 -0
  239. data/lib/fog/hp/requests/compute/get_server_details.rb +48 -0
  240. data/lib/fog/hp/requests/compute/get_vnc_console.rb +41 -0
  241. data/lib/fog/hp/requests/compute/get_windows_password.rb +40 -0
  242. data/lib/fog/hp/requests/compute/list_addresses.rb +37 -0
  243. data/lib/fog/hp/requests/compute/list_flavors.rb +40 -0
  244. data/lib/fog/hp/requests/compute/list_flavors_detail.rb +42 -0
  245. data/lib/fog/hp/requests/compute/list_images.rb +36 -0
  246. data/lib/fog/hp/requests/compute/list_images_detail.rb +45 -0
  247. data/lib/fog/hp/requests/compute/list_key_pairs.rb +40 -0
  248. data/lib/fog/hp/requests/compute/list_metadata.rb +52 -0
  249. data/lib/fog/hp/requests/compute/list_security_groups.rb +50 -0
  250. data/lib/fog/hp/requests/compute/list_server_addresses.rb +38 -0
  251. data/lib/fog/hp/requests/compute/list_server_private_addresses.rb +54 -0
  252. data/lib/fog/hp/requests/compute/list_server_public_addresses.rb +54 -0
  253. data/lib/fog/hp/requests/compute/list_server_volumes.rb +45 -0
  254. data/lib/fog/hp/requests/compute/list_servers.rb +37 -0
  255. data/lib/fog/hp/requests/compute/list_servers_detail.rb +52 -0
  256. data/lib/fog/hp/requests/compute/reboot_server.rb +30 -0
  257. data/lib/fog/hp/requests/compute/rebuild_server.rb +27 -0
  258. data/lib/fog/hp/requests/compute/release_address.rb +35 -0
  259. data/lib/fog/hp/requests/compute/resize_server.rb +35 -0
  260. data/lib/fog/hp/requests/compute/revert_resized_server.rb +31 -0
  261. data/lib/fog/hp/requests/compute/server_action.rb +23 -0
  262. data/lib/fog/hp/requests/compute/set_metadata.rb +53 -0
  263. data/lib/fog/hp/requests/compute/update_meta.rb +54 -0
  264. data/lib/fog/hp/requests/compute/update_metadata.rb +53 -0
  265. data/lib/fog/hp/requests/compute/update_server.rb +38 -0
  266. data/lib/fog/hp/requests/compute_v2/add_security_group.rb +36 -0
  267. data/lib/fog/hp/requests/compute_v2/allocate_address.rb +48 -0
  268. data/lib/fog/hp/requests/compute_v2/associate_address.rb +42 -0
  269. data/lib/fog/hp/requests/compute_v2/attach_volume.rb +76 -0
  270. data/lib/fog/hp/requests/compute_v2/create_image.rb +58 -0
  271. data/lib/fog/hp/requests/compute_v2/create_key_pair.rb +68 -0
  272. data/lib/fog/hp/requests/compute_v2/create_persistent_server.rb +177 -0
  273. data/lib/fog/hp/requests/compute_v2/create_server.rb +164 -0
  274. data/lib/fog/hp/requests/compute_v2/delete_image.rb +39 -0
  275. data/lib/fog/hp/requests/compute_v2/delete_key_pair.rb +34 -0
  276. data/lib/fog/hp/requests/compute_v2/delete_meta.rb +50 -0
  277. data/lib/fog/hp/requests/compute_v2/delete_server.rb +39 -0
  278. data/lib/fog/hp/requests/compute_v2/detach_volume.rb +43 -0
  279. data/lib/fog/hp/requests/compute_v2/disassociate_address.rb +35 -0
  280. data/lib/fog/hp/requests/compute_v2/get_address.rb +44 -0
  281. data/lib/fog/hp/requests/compute_v2/get_console_output.rb +37 -0
  282. data/lib/fog/hp/requests/compute_v2/get_flavor_details.rb +53 -0
  283. data/lib/fog/hp/requests/compute_v2/get_image_details.rb +50 -0
  284. data/lib/fog/hp/requests/compute_v2/get_key_pair.rb +40 -0
  285. data/lib/fog/hp/requests/compute_v2/get_meta.rb +52 -0
  286. data/lib/fog/hp/requests/compute_v2/get_server_details.rb +68 -0
  287. data/lib/fog/hp/requests/compute_v2/get_server_volume_details.rb +43 -0
  288. data/lib/fog/hp/requests/compute_v2/get_vnc_console.rb +41 -0
  289. data/lib/fog/hp/requests/compute_v2/get_windows_password.rb +40 -0
  290. data/lib/fog/hp/requests/compute_v2/list_addresses.rb +40 -0
  291. data/lib/fog/hp/requests/compute_v2/list_availability_zones.rb +43 -0
  292. data/lib/fog/hp/requests/compute_v2/list_flavors.rb +49 -0
  293. data/lib/fog/hp/requests/compute_v2/list_flavors_detail.rb +49 -0
  294. data/lib/fog/hp/requests/compute_v2/list_images.rb +48 -0
  295. data/lib/fog/hp/requests/compute_v2/list_images_detail.rb +62 -0
  296. data/lib/fog/hp/requests/compute_v2/list_key_pairs.rb +38 -0
  297. data/lib/fog/hp/requests/compute_v2/list_limits.rb +58 -0
  298. data/lib/fog/hp/requests/compute_v2/list_metadata.rb +52 -0
  299. data/lib/fog/hp/requests/compute_v2/list_server_addresses.rb +38 -0
  300. data/lib/fog/hp/requests/compute_v2/list_server_addresses_by_network.rb +42 -0
  301. data/lib/fog/hp/requests/compute_v2/list_server_volumes.rb +45 -0
  302. data/lib/fog/hp/requests/compute_v2/list_servers.rb +49 -0
  303. data/lib/fog/hp/requests/compute_v2/list_servers_detail.rb +76 -0
  304. data/lib/fog/hp/requests/compute_v2/reboot_server.rb +30 -0
  305. data/lib/fog/hp/requests/compute_v2/rebuild_server.rb +77 -0
  306. data/lib/fog/hp/requests/compute_v2/release_address.rb +34 -0
  307. data/lib/fog/hp/requests/compute_v2/remove_security_group.rb +33 -0
  308. data/lib/fog/hp/requests/compute_v2/server_action.rb +23 -0
  309. data/lib/fog/hp/requests/compute_v2/set_metadata.rb +53 -0
  310. data/lib/fog/hp/requests/compute_v2/update_meta.rb +54 -0
  311. data/lib/fog/hp/requests/compute_v2/update_metadata.rb +53 -0
  312. data/lib/fog/hp/requests/compute_v2/update_server.rb +69 -0
  313. data/lib/fog/hp/requests/dns/create_domain.rb +65 -0
  314. data/lib/fog/hp/requests/dns/create_record.rb +76 -0
  315. data/lib/fog/hp/requests/dns/delete_domain.rb +32 -0
  316. data/lib/fog/hp/requests/dns/delete_record.rb +34 -0
  317. data/lib/fog/hp/requests/dns/get_domain.rb +41 -0
  318. data/lib/fog/hp/requests/dns/get_record.rb +46 -0
  319. data/lib/fog/hp/requests/dns/get_servers_hosting_domain.rb +60 -0
  320. data/lib/fog/hp/requests/dns/list_domains.rb +36 -0
  321. data/lib/fog/hp/requests/dns/list_records_in_a_domain.rb +53 -0
  322. data/lib/fog/hp/requests/dns/update_domain.rb +61 -0
  323. data/lib/fog/hp/requests/dns/update_record.rb +66 -0
  324. data/lib/fog/hp/requests/lb/create_load_balancer.rb +109 -0
  325. data/lib/fog/hp/requests/lb/create_load_balancer_node.rb +68 -0
  326. data/lib/fog/hp/requests/lb/delete_load_balancer.rb +32 -0
  327. data/lib/fog/hp/requests/lb/delete_load_balancer_node.rb +43 -0
  328. data/lib/fog/hp/requests/lb/get_load_balancer.rb +57 -0
  329. data/lib/fog/hp/requests/lb/get_load_balancer_node.rb +51 -0
  330. data/lib/fog/hp/requests/lb/list_algorithms.rb +31 -0
  331. data/lib/fog/hp/requests/lb/list_limits.rb +36 -0
  332. data/lib/fog/hp/requests/lb/list_load_balancer_nodes.rb +39 -0
  333. data/lib/fog/hp/requests/lb/list_load_balancer_virtual_ips.rb +41 -0
  334. data/lib/fog/hp/requests/lb/list_load_balancers.rb +39 -0
  335. data/lib/fog/hp/requests/lb/list_protocols.rb +33 -0
  336. data/lib/fog/hp/requests/lb/list_versions.rb +24 -0
  337. data/lib/fog/hp/requests/lb/update_load_balancer.rb +45 -0
  338. data/lib/fog/hp/requests/lb/update_load_balancer_node.rb +55 -0
  339. data/lib/fog/hp/requests/network/add_router_interface.rb +73 -0
  340. data/lib/fog/hp/requests/network/associate_floating_ip.rb +69 -0
  341. data/lib/fog/hp/requests/network/create_floating_ip.rb +67 -0
  342. data/lib/fog/hp/requests/network/create_network.rb +65 -0
  343. data/lib/fog/hp/requests/network/create_port.rb +90 -0
  344. data/lib/fog/hp/requests/network/create_router.rb +62 -0
  345. data/lib/fog/hp/requests/network/create_security_group.rb +95 -0
  346. data/lib/fog/hp/requests/network/create_security_group_rule.rb +78 -0
  347. data/lib/fog/hp/requests/network/create_subnet.rb +95 -0
  348. data/lib/fog/hp/requests/network/delete_floating_ip.rb +32 -0
  349. data/lib/fog/hp/requests/network/delete_network.rb +32 -0
  350. data/lib/fog/hp/requests/network/delete_port.rb +32 -0
  351. data/lib/fog/hp/requests/network/delete_router.rb +32 -0
  352. data/lib/fog/hp/requests/network/delete_security_group.rb +32 -0
  353. data/lib/fog/hp/requests/network/delete_security_group_rule.rb +32 -0
  354. data/lib/fog/hp/requests/network/delete_subnet.rb +32 -0
  355. data/lib/fog/hp/requests/network/disassociate_floating_ip.rb +69 -0
  356. data/lib/fog/hp/requests/network/get_floating_ip.rb +44 -0
  357. data/lib/fog/hp/requests/network/get_network.rb +46 -0
  358. data/lib/fog/hp/requests/network/get_port.rb +51 -0
  359. data/lib/fog/hp/requests/network/get_router.rb +44 -0
  360. data/lib/fog/hp/requests/network/get_security_group.rb +52 -0
  361. data/lib/fog/hp/requests/network/get_security_group_rule.rb +47 -0
  362. data/lib/fog/hp/requests/network/get_subnet.rb +50 -0
  363. data/lib/fog/hp/requests/network/list_floating_ips.rb +44 -0
  364. data/lib/fog/hp/requests/network/list_networks.rb +58 -0
  365. data/lib/fog/hp/requests/network/list_ports.rb +50 -0
  366. data/lib/fog/hp/requests/network/list_routers.rb +43 -0
  367. data/lib/fog/hp/requests/network/list_security_group_rules.rb +48 -0
  368. data/lib/fog/hp/requests/network/list_security_groups.rb +53 -0
  369. data/lib/fog/hp/requests/network/list_subnets.rb +49 -0
  370. data/lib/fog/hp/requests/network/remove_router_interface.rb +65 -0
  371. data/lib/fog/hp/requests/network/update_network.rb +60 -0
  372. data/lib/fog/hp/requests/network/update_port.rb +73 -0
  373. data/lib/fog/hp/requests/network/update_router.rb +60 -0
  374. data/lib/fog/hp/requests/network/update_subnet.rb +70 -0
  375. data/lib/fog/hp/requests/storage/delete_container.rb +38 -0
  376. data/lib/fog/hp/requests/storage/delete_object.rb +39 -0
  377. data/lib/fog/hp/requests/storage/delete_shared_object.rb +33 -0
  378. data/lib/fog/hp/requests/storage/get_container.rb +87 -0
  379. data/lib/fog/hp/requests/storage/get_containers.rb +66 -0
  380. data/lib/fog/hp/requests/storage/get_object.rb +82 -0
  381. data/lib/fog/hp/requests/storage/get_object_temp_url.rb +26 -0
  382. data/lib/fog/hp/requests/storage/get_shared_container.rb +69 -0
  383. data/lib/fog/hp/requests/storage/get_shared_object.rb +61 -0
  384. data/lib/fog/hp/requests/storage/head_container.rb +36 -0
  385. data/lib/fog/hp/requests/storage/head_containers.rb +32 -0
  386. data/lib/fog/hp/requests/storage/head_object.rb +31 -0
  387. data/lib/fog/hp/requests/storage/head_shared_container.rb +40 -0
  388. data/lib/fog/hp/requests/storage/head_shared_object.rb +34 -0
  389. data/lib/fog/hp/requests/storage/post_container.rb +33 -0
  390. data/lib/fog/hp/requests/storage/post_object.rb +51 -0
  391. data/lib/fog/hp/requests/storage/put_container.rb +45 -0
  392. data/lib/fog/hp/requests/storage/put_object.rb +100 -0
  393. data/lib/fog/hp/requests/storage/put_shared_object.rb +80 -0
  394. data/lib/fog/hp/simple_http_instrumentor.rb +58 -0
  395. data/lib/fog/hp/storage.rb +438 -0
  396. data/lib/fog/internet_archive.rb +1 -0
  397. data/lib/fog/internet_archive/core.rb +291 -0
  398. data/lib/fog/internet_archive/models/storage/directories.rb +39 -0
  399. data/lib/fog/internet_archive/models/storage/directory.rb +105 -0
  400. data/lib/fog/internet_archive/models/storage/file.rb +254 -0
  401. data/lib/fog/internet_archive/models/storage/files.rb +119 -0
  402. data/lib/fog/internet_archive/models/storage/ia_attributes.rb +36 -0
  403. data/lib/fog/internet_archive/parsers/storage/access_control_list.rb +42 -0
  404. data/lib/fog/internet_archive/parsers/storage/complete_multipart_upload.rb +20 -0
  405. data/lib/fog/internet_archive/parsers/storage/copy_object.rb +18 -0
  406. data/lib/fog/internet_archive/parsers/storage/cors_configuration.rb +38 -0
  407. data/lib/fog/internet_archive/parsers/storage/delete_multiple_objects.rb +45 -0
  408. data/lib/fog/internet_archive/parsers/storage/get_bucket.rb +58 -0
  409. data/lib/fog/internet_archive/parsers/storage/get_bucket_lifecycle.rb +64 -0
  410. data/lib/fog/internet_archive/parsers/storage/get_bucket_location.rb +16 -0
  411. data/lib/fog/internet_archive/parsers/storage/get_bucket_logging.rb +36 -0
  412. data/lib/fog/internet_archive/parsers/storage/get_bucket_website.rb +22 -0
  413. data/lib/fog/internet_archive/parsers/storage/get_request_payment.rb +16 -0
  414. data/lib/fog/internet_archive/parsers/storage/get_service.rb +28 -0
  415. data/lib/fog/internet_archive/parsers/storage/initiate_multipart_upload.rb +20 -0
  416. data/lib/fog/internet_archive/parsers/storage/list_multipart_uploads.rb +52 -0
  417. data/lib/fog/internet_archive/parsers/storage/list_parts.rb +36 -0
  418. data/lib/fog/internet_archive/requests/storage/abort_multipart_upload.rb +27 -0
  419. data/lib/fog/internet_archive/requests/storage/acl_utils.rb +60 -0
  420. data/lib/fog/internet_archive/requests/storage/complete_multipart_upload.rb +46 -0
  421. data/lib/fog/internet_archive/requests/storage/copy_object.rb +77 -0
  422. data/lib/fog/internet_archive/requests/storage/cors_utils.rb +39 -0
  423. data/lib/fog/internet_archive/requests/storage/delete_bucket.rb +42 -0
  424. data/lib/fog/internet_archive/requests/storage/delete_bucket_cors.rb +26 -0
  425. data/lib/fog/internet_archive/requests/storage/delete_bucket_lifecycle.rb +26 -0
  426. data/lib/fog/internet_archive/requests/storage/delete_bucket_policy.rb +26 -0
  427. data/lib/fog/internet_archive/requests/storage/delete_bucket_website.rb +26 -0
  428. data/lib/fog/internet_archive/requests/storage/delete_multiple_objects.rb +88 -0
  429. data/lib/fog/internet_archive/requests/storage/delete_object.rb +46 -0
  430. data/lib/fog/internet_archive/requests/storage/get_bucket.rb +108 -0
  431. data/lib/fog/internet_archive/requests/storage/get_bucket_acl.rb +65 -0
  432. data/lib/fog/internet_archive/requests/storage/get_bucket_cors.rb +61 -0
  433. data/lib/fog/internet_archive/requests/storage/get_bucket_lifecycle.rb +35 -0
  434. data/lib/fog/internet_archive/requests/storage/get_bucket_location.rb +54 -0
  435. data/lib/fog/internet_archive/requests/storage/get_bucket_logging.rb +45 -0
  436. data/lib/fog/internet_archive/requests/storage/get_bucket_policy.rb +31 -0
  437. data/lib/fog/internet_archive/requests/storage/get_bucket_website.rb +38 -0
  438. data/lib/fog/internet_archive/requests/storage/get_object.rb +163 -0
  439. data/lib/fog/internet_archive/requests/storage/get_object_acl.rb +72 -0
  440. data/lib/fog/internet_archive/requests/storage/get_object_http_url.rb +48 -0
  441. data/lib/fog/internet_archive/requests/storage/get_object_https_url.rb +30 -0
  442. data/lib/fog/internet_archive/requests/storage/get_object_torrent.rb +45 -0
  443. data/lib/fog/internet_archive/requests/storage/get_object_url.rb +49 -0
  444. data/lib/fog/internet_archive/requests/storage/get_request_payment.rb +45 -0
  445. data/lib/fog/internet_archive/requests/storage/get_service.rb +50 -0
  446. data/lib/fog/internet_archive/requests/storage/head_object.rb +57 -0
  447. data/lib/fog/internet_archive/requests/storage/initiate_multipart_upload.rb +42 -0
  448. data/lib/fog/internet_archive/requests/storage/list_multipart_uploads.rb +52 -0
  449. data/lib/fog/internet_archive/requests/storage/list_parts.rb +53 -0
  450. data/lib/fog/internet_archive/requests/storage/post_object_hidden_fields.rb +36 -0
  451. data/lib/fog/internet_archive/requests/storage/put_bucket.rb +70 -0
  452. data/lib/fog/internet_archive/requests/storage/put_bucket_acl.rb +69 -0
  453. data/lib/fog/internet_archive/requests/storage/put_bucket_cors.rb +47 -0
  454. data/lib/fog/internet_archive/requests/storage/put_bucket_lifecycle.rb +76 -0
  455. data/lib/fog/internet_archive/requests/storage/put_bucket_logging.rb +79 -0
  456. data/lib/fog/internet_archive/requests/storage/put_bucket_policy.rb +25 -0
  457. data/lib/fog/internet_archive/requests/storage/put_bucket_website.rb +59 -0
  458. data/lib/fog/internet_archive/requests/storage/put_object.rb +94 -0
  459. data/lib/fog/internet_archive/requests/storage/put_object_acl.rb +73 -0
  460. data/lib/fog/internet_archive/requests/storage/put_object_url.rb +43 -0
  461. data/lib/fog/internet_archive/requests/storage/put_request_payment.rb +45 -0
  462. data/lib/fog/internet_archive/requests/storage/sync_clock.rb +24 -0
  463. data/lib/fog/internet_archive/requests/storage/upload_part.rb +39 -0
  464. data/lib/fog/internet_archive/signaturev4.rb +71 -0
  465. data/lib/fog/internet_archive/storage.rb +381 -0
  466. data/lib/fog/joyent.rb +12 -0
  467. data/lib/fog/joyent/analytics.rb +310 -0
  468. data/lib/fog/joyent/compute.rb +279 -0
  469. data/lib/fog/joyent/core.rb +10 -0
  470. data/lib/fog/joyent/errors.rb +91 -0
  471. data/lib/fog/joyent/models/analytics/field.rb +13 -0
  472. data/lib/fog/joyent/models/analytics/fields.rb +24 -0
  473. data/lib/fog/joyent/models/analytics/instrumentation.rb +82 -0
  474. data/lib/fog/joyent/models/analytics/instrumentations.rb +23 -0
  475. data/lib/fog/joyent/models/analytics/joyent_module.rb +13 -0
  476. data/lib/fog/joyent/models/analytics/joyent_modules.rb +24 -0
  477. data/lib/fog/joyent/models/analytics/metric.rb +17 -0
  478. data/lib/fog/joyent/models/analytics/metrics.rb +16 -0
  479. data/lib/fog/joyent/models/analytics/transformation.rb +13 -0
  480. data/lib/fog/joyent/models/analytics/transformations.rb +24 -0
  481. data/lib/fog/joyent/models/analytics/type.rb +16 -0
  482. data/lib/fog/joyent/models/analytics/types.rb +24 -0
  483. data/lib/fog/joyent/models/analytics/value.rb +20 -0
  484. data/lib/fog/joyent/models/compute/datacenter.rb +11 -0
  485. data/lib/fog/joyent/models/compute/datacenters.rb +21 -0
  486. data/lib/fog/joyent/models/compute/flavor.rb +19 -0
  487. data/lib/fog/joyent/models/compute/flavors.rb +21 -0
  488. data/lib/fog/joyent/models/compute/image.rb +26 -0
  489. data/lib/fog/joyent/models/compute/images.rb +30 -0
  490. data/lib/fog/joyent/models/compute/key.rb +19 -0
  491. data/lib/fog/joyent/models/compute/keys.rb +32 -0
  492. data/lib/fog/joyent/models/compute/network.rb +12 -0
  493. data/lib/fog/joyent/models/compute/networks.rb +14 -0
  494. data/lib/fog/joyent/models/compute/server.rb +124 -0
  495. data/lib/fog/joyent/models/compute/servers.rb +35 -0
  496. data/lib/fog/joyent/models/compute/snapshot.rb +44 -0
  497. data/lib/fog/joyent/models/compute/snapshots.rb +35 -0
  498. data/lib/fog/joyent/requests/analytics/create_instrumentation.rb +25 -0
  499. data/lib/fog/joyent/requests/analytics/delete_instrumentation.rb +23 -0
  500. data/lib/fog/joyent/requests/analytics/describe_analytics.rb +26 -0
  501. data/lib/fog/joyent/requests/analytics/get_instrumentation.rb +26 -0
  502. data/lib/fog/joyent/requests/analytics/get_instrumentation_value.rb +30 -0
  503. data/lib/fog/joyent/requests/analytics/list_instrumentations.rb +25 -0
  504. data/lib/fog/joyent/requests/compute/add_machine_tags.rb +19 -0
  505. data/lib/fog/joyent/requests/compute/create_key.rb +54 -0
  506. data/lib/fog/joyent/requests/compute/create_machine.rb +16 -0
  507. data/lib/fog/joyent/requests/compute/create_machine_snapshot.rb +16 -0
  508. data/lib/fog/joyent/requests/compute/delete_all_machine_metadata.rb +16 -0
  509. data/lib/fog/joyent/requests/compute/delete_all_machine_tags.rb +15 -0
  510. data/lib/fog/joyent/requests/compute/delete_key.rb +27 -0
  511. data/lib/fog/joyent/requests/compute/delete_machine.rb +15 -0
  512. data/lib/fog/joyent/requests/compute/delete_machine_metadata.rb +16 -0
  513. data/lib/fog/joyent/requests/compute/delete_machine_snapshot.rb +18 -0
  514. data/lib/fog/joyent/requests/compute/delete_machine_tag.rb +15 -0
  515. data/lib/fog/joyent/requests/compute/get_dataset.rb +27 -0
  516. data/lib/fog/joyent/requests/compute/get_image.rb +28 -0
  517. data/lib/fog/joyent/requests/compute/get_key.rb +29 -0
  518. data/lib/fog/joyent/requests/compute/get_machine.rb +29 -0
  519. data/lib/fog/joyent/requests/compute/get_machine_metadata.rb +24 -0
  520. data/lib/fog/joyent/requests/compute/get_machine_snapshot.rb +15 -0
  521. data/lib/fog/joyent/requests/compute/get_machine_tag.rb +18 -0
  522. data/lib/fog/joyent/requests/compute/get_package.rb +32 -0
  523. data/lib/fog/joyent/requests/compute/list_datacenters.rb +16 -0
  524. data/lib/fog/joyent/requests/compute/list_datasets.rb +24 -0
  525. data/lib/fog/joyent/requests/compute/list_images.rb +25 -0
  526. data/lib/fog/joyent/requests/compute/list_keys.rb +25 -0
  527. data/lib/fog/joyent/requests/compute/list_machine_snapshots.rb +15 -0
  528. data/lib/fog/joyent/requests/compute/list_machine_tags.rb +20 -0
  529. data/lib/fog/joyent/requests/compute/list_machines.rb +26 -0
  530. data/lib/fog/joyent/requests/compute/list_networks.rb +26 -0
  531. data/lib/fog/joyent/requests/compute/list_packages.rb +34 -0
  532. data/lib/fog/joyent/requests/compute/reboot_machine.rb +15 -0
  533. data/lib/fog/joyent/requests/compute/resize_machine.rb +16 -0
  534. data/lib/fog/joyent/requests/compute/start_machine.rb +16 -0
  535. data/lib/fog/joyent/requests/compute/start_machine_from_snapshot.rb +15 -0
  536. data/lib/fog/joyent/requests/compute/stop_machine.rb +16 -0
  537. data/lib/fog/joyent/requests/compute/update_machine_metadata.rb +15 -0
  538. data/lib/fog/linode/compute.rb +0 -3
  539. data/lib/fog/linode/models/compute/data_center.rb +0 -1
  540. data/lib/fog/linode/models/compute/flavor.rb +0 -3
  541. data/lib/fog/linode/models/compute/flavors.rb +1 -8
  542. data/lib/fog/linode/models/compute/image.rb +0 -2
  543. data/lib/fog/linode/models/compute/images.rb +1 -2
  544. data/lib/fog/linode/models/compute/kernel.rb +0 -3
  545. data/lib/fog/linode/models/compute/kernels.rb +8 -14
  546. data/lib/fog/linode/requests/compute/avail_kernels.rb +18 -17
  547. data/lib/fog/linode/requests/compute/avail_linodeplans.rb +2 -4
  548. data/lib/fog/linode/requests/compute/avail_stackscripts.rb +11 -6
  549. data/lib/fog/ninefold.rb +1 -0
  550. data/lib/fog/ninefold/compute.rb +144 -0
  551. data/lib/fog/ninefold/core.rb +11 -0
  552. data/lib/fog/ninefold/models/compute/address.rb +100 -0
  553. data/lib/fog/ninefold/models/compute/addresses.rb +27 -0
  554. data/lib/fog/ninefold/models/compute/flavor.rb +24 -0
  555. data/lib/fog/ninefold/models/compute/flavors.rb +26 -0
  556. data/lib/fog/ninefold/models/compute/image.rb +38 -0
  557. data/lib/fog/ninefold/models/compute/images.rb +26 -0
  558. data/lib/fog/ninefold/models/compute/ip_forwarding_rule.rb +76 -0
  559. data/lib/fog/ninefold/models/compute/ip_forwarding_rules.rb +27 -0
  560. data/lib/fog/ninefold/models/compute/server.rb +182 -0
  561. data/lib/fog/ninefold/models/compute/servers.rb +27 -0
  562. data/lib/fog/ninefold/requests/compute/assign_to_load_balancer_rule.rb +11 -0
  563. data/lib/fog/ninefold/requests/compute/associate_ip_address.rb +12 -0
  564. data/lib/fog/ninefold/requests/compute/change_service_for_virtual_machine.rb +12 -0
  565. data/lib/fog/ninefold/requests/compute/create_ip_forwarding_rule.rb +12 -0
  566. data/lib/fog/ninefold/requests/compute/create_load_balancer_rule.rb +11 -0
  567. data/lib/fog/ninefold/requests/compute/delete_ip_forwarding_rule.rb +12 -0
  568. data/lib/fog/ninefold/requests/compute/delete_load_balancer_rule.rb +11 -0
  569. data/lib/fog/ninefold/requests/compute/deploy_virtual_machine.rb +12 -0
  570. data/lib/fog/ninefold/requests/compute/destroy_virtual_machine.rb +12 -0
  571. data/lib/fog/ninefold/requests/compute/disable_static_nat.rb +12 -0
  572. data/lib/fog/ninefold/requests/compute/disassociate_ip_address.rb +12 -0
  573. data/lib/fog/ninefold/requests/compute/enable_static_nat.rb +12 -0
  574. data/lib/fog/ninefold/requests/compute/list_accounts.rb +12 -0
  575. data/lib/fog/ninefold/requests/compute/list_async_jobs.rb +12 -0
  576. data/lib/fog/ninefold/requests/compute/list_capabilities.rb +12 -0
  577. data/lib/fog/ninefold/requests/compute/list_disk_offerings.rb +12 -0
  578. data/lib/fog/ninefold/requests/compute/list_events.rb +12 -0
  579. data/lib/fog/ninefold/requests/compute/list_hypervisors.rb +12 -0
  580. data/lib/fog/ninefold/requests/compute/list_ip_forwarding_rules.rb +12 -0
  581. data/lib/fog/ninefold/requests/compute/list_load_balancer_rule_instances.rb +11 -0
  582. data/lib/fog/ninefold/requests/compute/list_load_balancer_rules.rb +11 -0
  583. data/lib/fog/ninefold/requests/compute/list_network_offerings.rb +12 -0
  584. data/lib/fog/ninefold/requests/compute/list_networks.rb +12 -0
  585. data/lib/fog/ninefold/requests/compute/list_public_ip_addresses.rb +12 -0
  586. data/lib/fog/ninefold/requests/compute/list_resource_limits.rb +12 -0
  587. data/lib/fog/ninefold/requests/compute/list_service_offerings.rb +12 -0
  588. data/lib/fog/ninefold/requests/compute/list_templates.rb +12 -0
  589. data/lib/fog/ninefold/requests/compute/list_virtual_machines.rb +12 -0
  590. data/lib/fog/ninefold/requests/compute/list_zones.rb +12 -0
  591. data/lib/fog/ninefold/requests/compute/query_async_job_result.rb +12 -0
  592. data/lib/fog/ninefold/requests/compute/reboot_virtual_machine.rb +12 -0
  593. data/lib/fog/ninefold/requests/compute/remove_from_load_balancer_rule.rb +11 -0
  594. data/lib/fog/ninefold/requests/compute/reset_password_for_virtual_machine.rb +12 -0
  595. data/lib/fog/ninefold/requests/compute/start_virtual_machine.rb +12 -0
  596. data/lib/fog/ninefold/requests/compute/stop_virtual_machine.rb +12 -0
  597. data/lib/fog/ninefold/requests/compute/update_load_balancer_rule.rb +11 -0
  598. data/lib/fog/ninefold/requests/compute/update_virtual_machine.rb +12 -0
  599. data/lib/fog/ninefold/storage.rb +53 -0
  600. data/lib/fog/opennebula/README.md +0 -0
  601. data/lib/fog/opennebula/compute.rb +19 -90
  602. data/lib/fog/opennebula/models/compute/flavor.rb +13 -13
  603. data/lib/fog/opennebula/models/compute/server.rb +1 -9
  604. data/lib/fog/opennebula/requests/compute/image_pool.rb +1 -0
  605. data/lib/fog/opennebula/requests/compute/list_vms.rb +26 -8
  606. data/lib/fog/opennebula/requests/compute/template_pool.rb +38 -20
  607. data/lib/fog/opennebula/requests/compute/vm_allocate.rb +15 -24
  608. data/lib/fog/opennebula/requests/compute/vm_destroy.rb +4 -13
  609. data/lib/fog/opennebula/requests/compute/vm_disk_snapshot.rb +2 -8
  610. data/lib/fog/opennebula/requests/compute/vm_resume.rb +23 -13
  611. data/lib/fog/opennebula/requests/compute/vm_shutdown.rb +1 -1
  612. data/lib/fog/opennebula/requests/compute/vm_stop.rb +10 -3
  613. data/lib/fog/openstack.rb +11 -0
  614. data/lib/fog/openstack/CHANGELOG.md +47 -0
  615. data/lib/fog/openstack/baremetal.rb +308 -0
  616. data/lib/fog/openstack/compute.rb +393 -0
  617. data/lib/fog/openstack/core.rb +594 -0
  618. data/lib/fog/openstack/docs/compute.md +681 -0
  619. data/lib/fog/openstack/docs/getting_started.md +81 -0
  620. data/lib/fog/openstack/docs/orchestration.md +318 -0
  621. data/lib/fog/openstack/docs/planning.md +270 -0
  622. data/lib/fog/openstack/docs/storage.md +453 -0
  623. data/lib/fog/openstack/examples/compute/basics.rb +50 -0
  624. data/lib/fog/openstack/examples/compute/block_device_mapping_v2.rb +32 -0
  625. data/lib/fog/openstack/examples/identity/basics.rb +68 -0
  626. data/lib/fog/openstack/examples/image/upload-test-image.rb +77 -0
  627. data/lib/fog/openstack/examples/network/network_subnets_routers.rb +62 -0
  628. data/lib/fog/openstack/examples/planning/basics.rb +53 -0
  629. data/lib/fog/openstack/examples/storage/set-account-quota.rb +66 -0
  630. data/lib/fog/openstack/identity.rb +63 -0
  631. data/lib/fog/openstack/identity_v2.rb +194 -0
  632. data/lib/fog/openstack/identity_v3.rb +172 -0
  633. data/lib/fog/openstack/image.rb +157 -0
  634. data/lib/fog/openstack/metering.rb +144 -0
  635. data/lib/fog/openstack/models/baremetal/chassis.rb +49 -0
  636. data/lib/fog/openstack/models/baremetal/chassis_collection.rb +44 -0
  637. data/lib/fog/openstack/models/baremetal/driver.rb +24 -0
  638. data/lib/fog/openstack/models/baremetal/drivers.rb +21 -0
  639. data/lib/fog/openstack/models/baremetal/node.rb +96 -0
  640. data/lib/fog/openstack/models/baremetal/nodes.rb +44 -0
  641. data/lib/fog/openstack/models/baremetal/port.rb +50 -0
  642. data/lib/fog/openstack/models/baremetal/ports.rb +44 -0
  643. data/lib/fog/openstack/models/collection.rb +45 -0
  644. data/lib/fog/openstack/models/compute/address.rb +67 -0
  645. data/lib/fog/openstack/models/compute/addresses.rb +28 -0
  646. data/lib/fog/openstack/models/compute/aggregate.rb +58 -0
  647. data/lib/fog/openstack/models/compute/aggregates.rb +26 -0
  648. data/lib/fog/openstack/models/compute/availability_zone.rb +14 -0
  649. data/lib/fog/openstack/models/compute/availability_zones.rb +22 -0
  650. data/lib/fog/openstack/models/compute/flavor.rb +52 -0
  651. data/lib/fog/openstack/models/compute/flavors.rb +29 -0
  652. data/lib/fog/openstack/models/compute/host.rb +28 -0
  653. data/lib/fog/openstack/models/compute/hosts.rb +28 -0
  654. data/lib/fog/openstack/models/compute/image.rb +48 -0
  655. data/lib/fog/openstack/models/compute/images.rb +38 -0
  656. data/lib/fog/openstack/models/compute/key_pair.rb +56 -0
  657. data/lib/fog/openstack/models/compute/key_pairs.rb +29 -0
  658. data/lib/fog/openstack/models/compute/metadata.rb +65 -0
  659. data/lib/fog/openstack/models/compute/metadatum.rb +27 -0
  660. data/lib/fog/openstack/models/compute/network.rb +13 -0
  661. data/lib/fog/openstack/models/compute/networks.rb +30 -0
  662. data/lib/fog/openstack/models/compute/security_group.rb +57 -0
  663. data/lib/fog/openstack/models/compute/security_group_rule.rb +32 -0
  664. data/lib/fog/openstack/models/compute/security_group_rules.rb +21 -0
  665. data/lib/fog/openstack/models/compute/security_groups.rb +24 -0
  666. data/lib/fog/openstack/models/compute/server.rb +395 -0
  667. data/lib/fog/openstack/models/compute/servers.rb +59 -0
  668. data/lib/fog/openstack/models/compute/service.rb +42 -0
  669. data/lib/fog/openstack/models/compute/services.rb +23 -0
  670. data/lib/fog/openstack/models/compute/snapshot.rb +32 -0
  671. data/lib/fog/openstack/models/compute/snapshots.rb +37 -0
  672. data/lib/fog/openstack/models/compute/tenant.rb +24 -0
  673. data/lib/fog/openstack/models/compute/tenants.rb +25 -0
  674. data/lib/fog/openstack/models/compute/volume.rb +52 -0
  675. data/lib/fog/openstack/models/compute/volumes.rb +37 -0
  676. data/lib/fog/openstack/models/identity_v2/ec2_credential.rb +39 -0
  677. data/lib/fog/openstack/models/identity_v2/ec2_credentials.rb +56 -0
  678. data/lib/fog/openstack/models/identity_v2/role.rb +52 -0
  679. data/lib/fog/openstack/models/identity_v2/roles.rb +22 -0
  680. data/lib/fog/openstack/models/identity_v2/tenant.rb +60 -0
  681. data/lib/fog/openstack/models/identity_v2/tenants.rb +31 -0
  682. data/lib/fog/openstack/models/identity_v2/user.rb +65 -0
  683. data/lib/fog/openstack/models/identity_v2/users.rb +45 -0
  684. data/lib/fog/openstack/models/identity_v3/domain.rb +43 -0
  685. data/lib/fog/openstack/models/identity_v3/domains.rb +35 -0
  686. data/lib/fog/openstack/models/identity_v3/endpoint.rb +46 -0
  687. data/lib/fog/openstack/models/identity_v3/endpoints.rb +26 -0
  688. data/lib/fog/openstack/models/identity_v3/group.rb +92 -0
  689. data/lib/fog/openstack/models/identity_v3/groups.rb +31 -0
  690. data/lib/fog/openstack/models/identity_v3/os_credential.rb +73 -0
  691. data/lib/fog/openstack/models/identity_v3/os_credentials.rb +31 -0
  692. data/lib/fog/openstack/models/identity_v3/policies.rb +31 -0
  693. data/lib/fog/openstack/models/identity_v3/policy.rb +42 -0
  694. data/lib/fog/openstack/models/identity_v3/project.rb +96 -0
  695. data/lib/fog/openstack/models/identity_v3/projects.rb +44 -0
  696. data/lib/fog/openstack/models/identity_v3/role.rb +40 -0
  697. data/lib/fog/openstack/models/identity_v3/role_assignment.rb +22 -0
  698. data/lib/fog/openstack/models/identity_v3/role_assignments.rb +25 -0
  699. data/lib/fog/openstack/models/identity_v3/roles.rb +39 -0
  700. data/lib/fog/openstack/models/identity_v3/service.rb +47 -0
  701. data/lib/fog/openstack/models/identity_v3/services.rb +31 -0
  702. data/lib/fog/openstack/models/identity_v3/token.rb +26 -0
  703. data/lib/fog/openstack/models/identity_v3/tokens.rb +40 -0
  704. data/lib/fog/openstack/models/identity_v3/user.rb +81 -0
  705. data/lib/fog/openstack/models/identity_v3/users.rb +35 -0
  706. data/lib/fog/openstack/models/image/image.rb +76 -0
  707. data/lib/fog/openstack/models/image/images.rb +67 -0
  708. data/lib/fog/openstack/models/meta_parent.rb +31 -0
  709. data/lib/fog/openstack/models/metering/meter.rb +0 -0
  710. data/lib/fog/openstack/models/metering/meters.rb +0 -0
  711. data/lib/fog/openstack/models/metering/resource.rb +15 -0
  712. data/lib/fog/openstack/models/metering/resources.rb +23 -0
  713. data/lib/fog/openstack/models/model.rb +44 -0
  714. data/lib/fog/openstack/models/network/floating_ip.rb +40 -0
  715. data/lib/fog/openstack/models/network/floating_ips.rb +32 -0
  716. data/lib/fog/openstack/models/network/lb_health_monitor.rb +57 -0
  717. data/lib/fog/openstack/models/network/lb_health_monitors.rb +32 -0
  718. data/lib/fog/openstack/models/network/lb_member.rb +42 -0
  719. data/lib/fog/openstack/models/network/lb_members.rb +32 -0
  720. data/lib/fog/openstack/models/network/lb_pool.rb +67 -0
  721. data/lib/fog/openstack/models/network/lb_pools.rb +32 -0
  722. data/lib/fog/openstack/models/network/lb_vip.rb +48 -0
  723. data/lib/fog/openstack/models/network/lb_vips.rb +32 -0
  724. data/lib/fog/openstack/models/network/network.rb +43 -0
  725. data/lib/fog/openstack/models/network/networks.rb +32 -0
  726. data/lib/fog/openstack/models/network/port.rb +42 -0
  727. data/lib/fog/openstack/models/network/ports.rb +32 -0
  728. data/lib/fog/openstack/models/network/router.rb +61 -0
  729. data/lib/fog/openstack/models/network/routers.rb +32 -0
  730. data/lib/fog/openstack/models/network/security_group.rb +32 -0
  731. data/lib/fog/openstack/models/network/security_group_rule.rb +33 -0
  732. data/lib/fog/openstack/models/network/security_group_rules.rb +32 -0
  733. data/lib/fog/openstack/models/network/security_groups.rb +32 -0
  734. data/lib/fog/openstack/models/network/subnet.rb +44 -0
  735. data/lib/fog/openstack/models/network/subnets.rb +32 -0
  736. data/lib/fog/openstack/models/orchestration/event.rb +20 -0
  737. data/lib/fog/openstack/models/orchestration/events.rb +31 -0
  738. data/lib/fog/openstack/models/orchestration/resource.rb +32 -0
  739. data/lib/fog/openstack/models/orchestration/resource_schemas.rb +17 -0
  740. data/lib/fog/openstack/models/orchestration/resources.rb +36 -0
  741. data/lib/fog/openstack/models/orchestration/stack.rb +120 -0
  742. data/lib/fog/openstack/models/orchestration/stacks.rb +64 -0
  743. data/lib/fog/openstack/models/orchestration/template.rb +15 -0
  744. data/lib/fog/openstack/models/orchestration/templates.rb +45 -0
  745. data/lib/fog/openstack/models/planning/plan.rb +70 -0
  746. data/lib/fog/openstack/models/planning/plans.rb +31 -0
  747. data/lib/fog/openstack/models/planning/role.rb +23 -0
  748. data/lib/fog/openstack/models/planning/roles.rb +16 -0
  749. data/lib/fog/openstack/models/storage/directories.rb +36 -0
  750. data/lib/fog/openstack/models/storage/directory.rb +50 -0
  751. data/lib/fog/openstack/models/storage/file.rb +176 -0
  752. data/lib/fog/openstack/models/storage/files.rb +101 -0
  753. data/lib/fog/openstack/models/volume/availability_zone.rb +13 -0
  754. data/lib/fog/openstack/models/volume/availability_zones.rb +17 -0
  755. data/lib/fog/openstack/models/volume/transfer.rb +36 -0
  756. data/lib/fog/openstack/models/volume/transfers.rb +38 -0
  757. data/lib/fog/openstack/models/volume/volume.rb +48 -0
  758. data/lib/fog/openstack/models/volume/volume_type.rb +39 -0
  759. data/lib/fog/openstack/models/volume/volume_types.rb +25 -0
  760. data/lib/fog/openstack/models/volume/volumes.rb +38 -0
  761. data/lib/fog/openstack/network.rb +292 -0
  762. data/lib/fog/openstack/orchestration.rb +191 -0
  763. data/lib/fog/openstack/planning.rb +173 -0
  764. data/lib/fog/openstack/requests/baremetal/create_chassis.rb +44 -0
  765. data/lib/fog/openstack/requests/baremetal/create_node.rb +54 -0
  766. data/lib/fog/openstack/requests/baremetal/create_port.rb +46 -0
  767. data/lib/fog/openstack/requests/baremetal/delete_chassis.rb +25 -0
  768. data/lib/fog/openstack/requests/baremetal/delete_node.rb +25 -0
  769. data/lib/fog/openstack/requests/baremetal/delete_port.rb +25 -0
  770. data/lib/fog/openstack/requests/baremetal/get_chassis.rb +24 -0
  771. data/lib/fog/openstack/requests/baremetal/get_driver.rb +24 -0
  772. data/lib/fog/openstack/requests/baremetal/get_driver_properties.rb +40 -0
  773. data/lib/fog/openstack/requests/baremetal/get_node.rb +24 -0
  774. data/lib/fog/openstack/requests/baremetal/get_port.rb +24 -0
  775. data/lib/fog/openstack/requests/baremetal/list_chassis.rb +42 -0
  776. data/lib/fog/openstack/requests/baremetal/list_chassis_detailed.rb +25 -0
  777. data/lib/fog/openstack/requests/baremetal/list_drivers.rb +25 -0
  778. data/lib/fog/openstack/requests/baremetal/list_nodes.rb +34 -0
  779. data/lib/fog/openstack/requests/baremetal/list_nodes_detailed.rb +25 -0
  780. data/lib/fog/openstack/requests/baremetal/list_ports.rb +42 -0
  781. data/lib/fog/openstack/requests/baremetal/list_ports_detailed.rb +25 -0
  782. data/lib/fog/openstack/requests/baremetal/patch_chassis.rb +42 -0
  783. data/lib/fog/openstack/requests/baremetal/patch_node.rb +41 -0
  784. data/lib/fog/openstack/requests/baremetal/patch_port.rb +41 -0
  785. data/lib/fog/openstack/requests/baremetal/set_node_maintenance.rb +36 -0
  786. data/lib/fog/openstack/requests/baremetal/set_node_power_state.rb +35 -0
  787. data/lib/fog/openstack/requests/baremetal/set_node_provision_state.rb +38 -0
  788. data/lib/fog/openstack/requests/baremetal/unset_node_maintenance.rb +36 -0
  789. data/lib/fog/openstack/requests/compute/add_aggregate_host.rb +30 -0
  790. data/lib/fog/openstack/requests/compute/add_fixed_ip.rb +29 -0
  791. data/lib/fog/openstack/requests/compute/add_flavor_access.rb +31 -0
  792. data/lib/fog/openstack/requests/compute/add_security_group.rb +20 -0
  793. data/lib/fog/openstack/requests/compute/allocate_address.rb +39 -0
  794. data/lib/fog/openstack/requests/compute/associate_address.rb +30 -0
  795. data/lib/fog/openstack/requests/compute/attach_volume.rb +38 -0
  796. data/lib/fog/openstack/requests/compute/boot_from_snapshot.rb +41 -0
  797. data/lib/fog/openstack/requests/compute/change_server_password.rb +20 -0
  798. data/lib/fog/openstack/requests/compute/confirm_resize_server.rb +20 -0
  799. data/lib/fog/openstack/requests/compute/create_aggregate.rb +42 -0
  800. data/lib/fog/openstack/requests/compute/create_flavor.rb +85 -0
  801. data/lib/fog/openstack/requests/compute/create_flavor_metadata.rb +38 -0
  802. data/lib/fog/openstack/requests/compute/create_image.rb +44 -0
  803. data/lib/fog/openstack/requests/compute/create_key_pair.rb +46 -0
  804. data/lib/fog/openstack/requests/compute/create_security_group.rb +50 -0
  805. data/lib/fog/openstack/requests/compute/create_security_group_rule.rb +57 -0
  806. data/lib/fog/openstack/requests/compute/create_server.rb +185 -0
  807. data/lib/fog/openstack/requests/compute/create_volume.rb +51 -0
  808. data/lib/fog/openstack/requests/compute/create_volume_snapshot.rb +44 -0
  809. data/lib/fog/openstack/requests/compute/delete_aggregate.rb +28 -0
  810. data/lib/fog/openstack/requests/compute/delete_flavor.rb +28 -0
  811. data/lib/fog/openstack/requests/compute/delete_image.rb +35 -0
  812. data/lib/fog/openstack/requests/compute/delete_key_pair.rb +29 -0
  813. data/lib/fog/openstack/requests/compute/delete_meta.rb +35 -0
  814. data/lib/fog/openstack/requests/compute/delete_metadata.rb +23 -0
  815. data/lib/fog/openstack/requests/compute/delete_security_group.rb +31 -0
  816. data/lib/fog/openstack/requests/compute/delete_security_group_rule.rb +31 -0
  817. data/lib/fog/openstack/requests/compute/delete_server.rb +34 -0
  818. data/lib/fog/openstack/requests/compute/delete_service.rb +32 -0
  819. data/lib/fog/openstack/requests/compute/delete_snapshot.rb +23 -0
  820. data/lib/fog/openstack/requests/compute/delete_volume.rb +28 -0
  821. data/lib/fog/openstack/requests/compute/detach_volume.rb +28 -0
  822. data/lib/fog/openstack/requests/compute/disable_service.rb +37 -0
  823. data/lib/fog/openstack/requests/compute/disable_service_log_reason.rb +38 -0
  824. data/lib/fog/openstack/requests/compute/disassociate_address.rb +25 -0
  825. data/lib/fog/openstack/requests/compute/enable_service.rb +38 -0
  826. data/lib/fog/openstack/requests/compute/get_address.rb +38 -0
  827. data/lib/fog/openstack/requests/compute/get_aggregate.rb +26 -0
  828. data/lib/fog/openstack/requests/compute/get_console_output.rb +24 -0
  829. data/lib/fog/openstack/requests/compute/get_flavor_details.rb +39 -0
  830. data/lib/fog/openstack/requests/compute/get_flavor_metadata.rb +27 -0
  831. data/lib/fog/openstack/requests/compute/get_host_details.rb +66 -0
  832. data/lib/fog/openstack/requests/compute/get_hypervisor_statistics.rb +39 -0
  833. data/lib/fog/openstack/requests/compute/get_image_details.rb +28 -0
  834. data/lib/fog/openstack/requests/compute/get_limits.rb +89 -0
  835. data/lib/fog/openstack/requests/compute/get_metadata.rb +24 -0
  836. data/lib/fog/openstack/requests/compute/get_quota.rb +26 -0
  837. data/lib/fog/openstack/requests/compute/get_quota_defaults.rb +26 -0
  838. data/lib/fog/openstack/requests/compute/get_security_group.rb +37 -0
  839. data/lib/fog/openstack/requests/compute/get_security_group_rule.rb +38 -0
  840. data/lib/fog/openstack/requests/compute/get_server_details.rb +28 -0
  841. data/lib/fog/openstack/requests/compute/get_server_volumes.rb +27 -0
  842. data/lib/fog/openstack/requests/compute/get_snapshot_details.rb +34 -0
  843. data/lib/fog/openstack/requests/compute/get_usage.rb +51 -0
  844. data/lib/fog/openstack/requests/compute/get_vnc_console.rb +40 -0
  845. data/lib/fog/openstack/requests/compute/get_volume_details.rb +28 -0
  846. data/lib/fog/openstack/requests/compute/list_address_pools.rb +28 -0
  847. data/lib/fog/openstack/requests/compute/list_addresses.rb +28 -0
  848. data/lib/fog/openstack/requests/compute/list_aggregates.rb +36 -0
  849. data/lib/fog/openstack/requests/compute/list_all_addresses.rb +62 -0
  850. data/lib/fog/openstack/requests/compute/list_flavors.rb +35 -0
  851. data/lib/fog/openstack/requests/compute/list_flavors_detail.rb +35 -0
  852. data/lib/fog/openstack/requests/compute/list_hosts.rb +28 -0
  853. data/lib/fog/openstack/requests/compute/list_images.rb +29 -0
  854. data/lib/fog/openstack/requests/compute/list_images_detail.rb +36 -0
  855. data/lib/fog/openstack/requests/compute/list_key_pairs.rb +38 -0
  856. data/lib/fog/openstack/requests/compute/list_metadata.rb +24 -0
  857. data/lib/fog/openstack/requests/compute/list_private_addresses.rb +28 -0
  858. data/lib/fog/openstack/requests/compute/list_public_addresses.rb +28 -0
  859. data/lib/fog/openstack/requests/compute/list_security_groups.rb +69 -0
  860. data/lib/fog/openstack/requests/compute/list_servers.rb +36 -0
  861. data/lib/fog/openstack/requests/compute/list_servers_detail.rb +43 -0
  862. data/lib/fog/openstack/requests/compute/list_services.rb +72 -0
  863. data/lib/fog/openstack/requests/compute/list_snapshots.rb +41 -0
  864. data/lib/fog/openstack/requests/compute/list_snapshots_detail.rb +27 -0
  865. data/lib/fog/openstack/requests/compute/list_tenants.rb +45 -0
  866. data/lib/fog/openstack/requests/compute/list_tenants_with_flavor_access.rb +26 -0
  867. data/lib/fog/openstack/requests/compute/list_usages.rb +41 -0
  868. data/lib/fog/openstack/requests/compute/list_volumes.rb +39 -0
  869. data/lib/fog/openstack/requests/compute/list_volumes_detail.rb +25 -0
  870. data/lib/fog/openstack/requests/compute/list_zones.rb +33 -0
  871. data/lib/fog/openstack/requests/compute/list_zones_detailed.rb +55 -0
  872. data/lib/fog/openstack/requests/compute/live_migrate_server.rb +26 -0
  873. data/lib/fog/openstack/requests/compute/migrate_server.rb +20 -0
  874. data/lib/fog/openstack/requests/compute/pause_server.rb +24 -0
  875. data/lib/fog/openstack/requests/compute/reboot_server.rb +20 -0
  876. data/lib/fog/openstack/requests/compute/rebuild_server.rb +34 -0
  877. data/lib/fog/openstack/requests/compute/release_address.rb +29 -0
  878. data/lib/fog/openstack/requests/compute/remove_aggregate_host.rb +30 -0
  879. data/lib/fog/openstack/requests/compute/remove_fixed_ip.rb +29 -0
  880. data/lib/fog/openstack/requests/compute/remove_flavor_access.rb +31 -0
  881. data/lib/fog/openstack/requests/compute/remove_security_group.rb +20 -0
  882. data/lib/fog/openstack/requests/compute/rescue_server.rb +24 -0
  883. data/lib/fog/openstack/requests/compute/reset_server_state.rb +20 -0
  884. data/lib/fog/openstack/requests/compute/resize_server.rb +20 -0
  885. data/lib/fog/openstack/requests/compute/resume_server.rb +24 -0
  886. data/lib/fog/openstack/requests/compute/revert_resize_server.rb +26 -0
  887. data/lib/fog/openstack/requests/compute/server_action.rb +16 -0
  888. data/lib/fog/openstack/requests/compute/server_actions.rb +27 -0
  889. data/lib/fog/openstack/requests/compute/server_diagnostics.rb +25 -0
  890. data/lib/fog/openstack/requests/compute/set_metadata.rb +37 -0
  891. data/lib/fog/openstack/requests/compute/set_tenant.rb +19 -0
  892. data/lib/fog/openstack/requests/compute/shelve_offload_server.rb +24 -0
  893. data/lib/fog/openstack/requests/compute/shelve_server.rb +24 -0
  894. data/lib/fog/openstack/requests/compute/start_server.rb +24 -0
  895. data/lib/fog/openstack/requests/compute/stop_server.rb +24 -0
  896. data/lib/fog/openstack/requests/compute/suspend_server.rb +24 -0
  897. data/lib/fog/openstack/requests/compute/unpause_server.rb +24 -0
  898. data/lib/fog/openstack/requests/compute/unshelve_server.rb +24 -0
  899. data/lib/fog/openstack/requests/compute/update_aggregate.rb +37 -0
  900. data/lib/fog/openstack/requests/compute/update_aggregate_metadata.rb +30 -0
  901. data/lib/fog/openstack/requests/compute/update_meta.rb +38 -0
  902. data/lib/fog/openstack/requests/compute/update_metadata.rb +38 -0
  903. data/lib/fog/openstack/requests/compute/update_quota.rb +28 -0
  904. data/lib/fog/openstack/requests/compute/update_server.rb +31 -0
  905. data/lib/fog/openstack/requests/identity_v2/add_user_to_tenant.rb +36 -0
  906. data/lib/fog/openstack/requests/identity_v2/check_token.rb +22 -0
  907. data/lib/fog/openstack/requests/identity_v2/create_ec2_credential.rb +59 -0
  908. data/lib/fog/openstack/requests/identity_v2/create_role.rb +38 -0
  909. data/lib/fog/openstack/requests/identity_v2/create_tenant.rb +34 -0
  910. data/lib/fog/openstack/requests/identity_v2/create_user.rb +45 -0
  911. data/lib/fog/openstack/requests/identity_v2/create_user_role.rb +26 -0
  912. data/lib/fog/openstack/requests/identity_v2/delete_ec2_credential.rb +43 -0
  913. data/lib/fog/openstack/requests/identity_v2/delete_role.rb +30 -0
  914. data/lib/fog/openstack/requests/identity_v2/delete_tenant.rb +33 -0
  915. data/lib/fog/openstack/requests/identity_v2/delete_user.rb +30 -0
  916. data/lib/fog/openstack/requests/identity_v2/delete_user_role.rb +25 -0
  917. data/lib/fog/openstack/requests/identity_v2/get_ec2_credential.rb +50 -0
  918. data/lib/fog/openstack/requests/identity_v2/get_role.rb +30 -0
  919. data/lib/fog/openstack/requests/identity_v2/get_tenant.rb +33 -0
  920. data/lib/fog/openstack/requests/identity_v2/get_tenants_by_id.rb +20 -0
  921. data/lib/fog/openstack/requests/identity_v2/get_tenants_by_name.rb +20 -0
  922. data/lib/fog/openstack/requests/identity_v2/get_user_by_id.rb +34 -0
  923. data/lib/fog/openstack/requests/identity_v2/get_user_by_name.rb +29 -0
  924. data/lib/fog/openstack/requests/identity_v2/list_ec2_credentials.rb +61 -0
  925. data/lib/fog/openstack/requests/identity_v2/list_endpoints_for_token.rb +20 -0
  926. data/lib/fog/openstack/requests/identity_v2/list_roles.rb +34 -0
  927. data/lib/fog/openstack/requests/identity_v2/list_roles_for_user_on_tenant.rb +32 -0
  928. data/lib/fog/openstack/requests/identity_v2/list_tenants.rb +53 -0
  929. data/lib/fog/openstack/requests/identity_v2/list_user_global_roles.rb +20 -0
  930. data/lib/fog/openstack/requests/identity_v2/list_users.rb +47 -0
  931. data/lib/fog/openstack/requests/identity_v2/remove_user_from_tenant.rb +22 -0
  932. data/lib/fog/openstack/requests/identity_v2/set_tenant.rb +21 -0
  933. data/lib/fog/openstack/requests/identity_v2/update_tenant.rb +30 -0
  934. data/lib/fog/openstack/requests/identity_v2/update_user.rb +34 -0
  935. data/lib/fog/openstack/requests/identity_v2/validate_token.rb +22 -0
  936. data/lib/fog/openstack/requests/identity_v3/add_user_to_group.rb +20 -0
  937. data/lib/fog/openstack/requests/identity_v3/auth_domains.rb +24 -0
  938. data/lib/fog/openstack/requests/identity_v3/auth_projects.rb +24 -0
  939. data/lib/fog/openstack/requests/identity_v3/check_domain_group_role.rb +20 -0
  940. data/lib/fog/openstack/requests/identity_v3/check_domain_user_role.rb +20 -0
  941. data/lib/fog/openstack/requests/identity_v3/check_project_group_role.rb +20 -0
  942. data/lib/fog/openstack/requests/identity_v3/check_project_user_role.rb +20 -0
  943. data/lib/fog/openstack/requests/identity_v3/create_domain.rb +21 -0
  944. data/lib/fog/openstack/requests/identity_v3/create_endpoint.rb +21 -0
  945. data/lib/fog/openstack/requests/identity_v3/create_group.rb +21 -0
  946. data/lib/fog/openstack/requests/identity_v3/create_os_credential.rb +21 -0
  947. data/lib/fog/openstack/requests/identity_v3/create_policy.rb +21 -0
  948. data/lib/fog/openstack/requests/identity_v3/create_project.rb +21 -0
  949. data/lib/fog/openstack/requests/identity_v3/create_role.rb +21 -0
  950. data/lib/fog/openstack/requests/identity_v3/create_service.rb +21 -0
  951. data/lib/fog/openstack/requests/identity_v3/create_user.rb +21 -0
  952. data/lib/fog/openstack/requests/identity_v3/delete_domain.rb +20 -0
  953. data/lib/fog/openstack/requests/identity_v3/delete_endpoint.rb +20 -0
  954. data/lib/fog/openstack/requests/identity_v3/delete_group.rb +20 -0
  955. data/lib/fog/openstack/requests/identity_v3/delete_os_credential.rb +20 -0
  956. data/lib/fog/openstack/requests/identity_v3/delete_policy.rb +20 -0
  957. data/lib/fog/openstack/requests/identity_v3/delete_project.rb +20 -0
  958. data/lib/fog/openstack/requests/identity_v3/delete_role.rb +20 -0
  959. data/lib/fog/openstack/requests/identity_v3/delete_service.rb +20 -0
  960. data/lib/fog/openstack/requests/identity_v3/delete_user.rb +20 -0
  961. data/lib/fog/openstack/requests/identity_v3/get_domain.rb +23 -0
  962. data/lib/fog/openstack/requests/identity_v3/get_endpoint.rb +23 -0
  963. data/lib/fog/openstack/requests/identity_v3/get_group.rb +23 -0
  964. data/lib/fog/openstack/requests/identity_v3/get_os_credential.rb +23 -0
  965. data/lib/fog/openstack/requests/identity_v3/get_policy.rb +23 -0
  966. data/lib/fog/openstack/requests/identity_v3/get_project.rb +23 -0
  967. data/lib/fog/openstack/requests/identity_v3/get_role.rb +23 -0
  968. data/lib/fog/openstack/requests/identity_v3/get_service.rb +23 -0
  969. data/lib/fog/openstack/requests/identity_v3/get_user.rb +23 -0
  970. data/lib/fog/openstack/requests/identity_v3/grant_domain_group_role.rb +20 -0
  971. data/lib/fog/openstack/requests/identity_v3/grant_domain_user_role.rb +20 -0
  972. data/lib/fog/openstack/requests/identity_v3/grant_project_group_role.rb +20 -0
  973. data/lib/fog/openstack/requests/identity_v3/grant_project_user_role.rb +20 -0
  974. data/lib/fog/openstack/requests/identity_v3/group_user_check.rb +20 -0
  975. data/lib/fog/openstack/requests/identity_v3/list_domain_group_roles.rb +23 -0
  976. data/lib/fog/openstack/requests/identity_v3/list_domain_user_roles.rb +23 -0
  977. data/lib/fog/openstack/requests/identity_v3/list_domains.rb +24 -0
  978. data/lib/fog/openstack/requests/identity_v3/list_endpoints.rb +24 -0
  979. data/lib/fog/openstack/requests/identity_v3/list_group_users.rb +24 -0
  980. data/lib/fog/openstack/requests/identity_v3/list_groups.rb +32 -0
  981. data/lib/fog/openstack/requests/identity_v3/list_os_credentials.rb +24 -0
  982. data/lib/fog/openstack/requests/identity_v3/list_policies.rb +24 -0
  983. data/lib/fog/openstack/requests/identity_v3/list_project_group_roles.rb +23 -0
  984. data/lib/fog/openstack/requests/identity_v3/list_project_user_roles.rb +23 -0
  985. data/lib/fog/openstack/requests/identity_v3/list_projects.rb +31 -0
  986. data/lib/fog/openstack/requests/identity_v3/list_role_assignments.rb +39 -0
  987. data/lib/fog/openstack/requests/identity_v3/list_roles.rb +24 -0
  988. data/lib/fog/openstack/requests/identity_v3/list_services.rb +24 -0
  989. data/lib/fog/openstack/requests/identity_v3/list_user_groups.rb +23 -0
  990. data/lib/fog/openstack/requests/identity_v3/list_user_projects.rb +23 -0
  991. data/lib/fog/openstack/requests/identity_v3/list_users.rb +24 -0
  992. data/lib/fog/openstack/requests/identity_v3/remove_user_from_group.rb +20 -0
  993. data/lib/fog/openstack/requests/identity_v3/revoke_domain_group_role.rb +20 -0
  994. data/lib/fog/openstack/requests/identity_v3/revoke_domain_user_role.rb +20 -0
  995. data/lib/fog/openstack/requests/identity_v3/revoke_project_group_role.rb +20 -0
  996. data/lib/fog/openstack/requests/identity_v3/revoke_project_user_role.rb +20 -0
  997. data/lib/fog/openstack/requests/identity_v3/token_authenticate.rb +21 -0
  998. data/lib/fog/openstack/requests/identity_v3/token_check.rb +21 -0
  999. data/lib/fog/openstack/requests/identity_v3/token_revoke.rb +21 -0
  1000. data/lib/fog/openstack/requests/identity_v3/token_validate.rb +22 -0
  1001. data/lib/fog/openstack/requests/identity_v3/update_domain.rb +21 -0
  1002. data/lib/fog/openstack/requests/identity_v3/update_endpoint.rb +21 -0
  1003. data/lib/fog/openstack/requests/identity_v3/update_group.rb +21 -0
  1004. data/lib/fog/openstack/requests/identity_v3/update_os_credential.rb +21 -0
  1005. data/lib/fog/openstack/requests/identity_v3/update_policy.rb +21 -0
  1006. data/lib/fog/openstack/requests/identity_v3/update_project.rb +21 -0
  1007. data/lib/fog/openstack/requests/identity_v3/update_role.rb +21 -0
  1008. data/lib/fog/openstack/requests/identity_v3/update_service.rb +21 -0
  1009. data/lib/fog/openstack/requests/identity_v3/update_user.rb +21 -0
  1010. data/lib/fog/openstack/requests/image/add_member_to_image.rb +23 -0
  1011. data/lib/fog/openstack/requests/image/create_image.rb +76 -0
  1012. data/lib/fog/openstack/requests/image/delete_image.rb +23 -0
  1013. data/lib/fog/openstack/requests/image/get_image.rb +45 -0
  1014. data/lib/fog/openstack/requests/image/get_image_by_id.rb +32 -0
  1015. data/lib/fog/openstack/requests/image/get_image_members.rb +29 -0
  1016. data/lib/fog/openstack/requests/image/get_shared_images.rb +29 -0
  1017. data/lib/fog/openstack/requests/image/list_public_images.rb +33 -0
  1018. data/lib/fog/openstack/requests/image/list_public_images_detailed.rb +35 -0
  1019. data/lib/fog/openstack/requests/image/remove_member_from_image.rb +23 -0
  1020. data/lib/fog/openstack/requests/image/set_tenant.rb +19 -0
  1021. data/lib/fog/openstack/requests/image/update_image.rb +64 -0
  1022. data/lib/fog/openstack/requests/image/update_image_members.rb +37 -0
  1023. data/lib/fog/openstack/requests/metering/get_resource.rb +28 -0
  1024. data/lib/fog/openstack/requests/metering/get_samples.rb +50 -0
  1025. data/lib/fog/openstack/requests/metering/get_statistics.rb +51 -0
  1026. data/lib/fog/openstack/requests/metering/list_meters.rb +45 -0
  1027. data/lib/fog/openstack/requests/metering/list_resources.rb +28 -0
  1028. data/lib/fog/openstack/requests/network/add_router_interface.rb +54 -0
  1029. data/lib/fog/openstack/requests/network/associate_floating_ip.rb +47 -0
  1030. data/lib/fog/openstack/requests/network/associate_lb_health_monitor.rb +37 -0
  1031. data/lib/fog/openstack/requests/network/create_floating_ip.rb +45 -0
  1032. data/lib/fog/openstack/requests/network/create_lb_health_monitor.rb +54 -0
  1033. data/lib/fog/openstack/requests/network/create_lb_member.rb +51 -0
  1034. data/lib/fog/openstack/requests/network/create_lb_pool.rb +58 -0
  1035. data/lib/fog/openstack/requests/network/create_lb_vip.rb +58 -0
  1036. data/lib/fog/openstack/requests/network/create_network.rb +97 -0
  1037. data/lib/fog/openstack/requests/network/create_port.rb +53 -0
  1038. data/lib/fog/openstack/requests/network/create_router.rb +76 -0
  1039. data/lib/fog/openstack/requests/network/create_security_group.rb +94 -0
  1040. data/lib/fog/openstack/requests/network/create_security_group_rule.rb +79 -0
  1041. data/lib/fog/openstack/requests/network/create_subnet.rb +54 -0
  1042. data/lib/fog/openstack/requests/network/delete_floating_ip.rb +28 -0
  1043. data/lib/fog/openstack/requests/network/delete_lb_health_monitor.rb +28 -0
  1044. data/lib/fog/openstack/requests/network/delete_lb_member.rb +28 -0
  1045. data/lib/fog/openstack/requests/network/delete_lb_pool.rb +28 -0
  1046. data/lib/fog/openstack/requests/network/delete_lb_vip.rb +28 -0
  1047. data/lib/fog/openstack/requests/network/delete_network.rb +28 -0
  1048. data/lib/fog/openstack/requests/network/delete_port.rb +28 -0
  1049. data/lib/fog/openstack/requests/network/delete_quota.rb +23 -0
  1050. data/lib/fog/openstack/requests/network/delete_router.rb +28 -0
  1051. data/lib/fog/openstack/requests/network/delete_security_group.rb +32 -0
  1052. data/lib/fog/openstack/requests/network/delete_security_group_rule.rb +32 -0
  1053. data/lib/fog/openstack/requests/network/delete_subnet.rb +28 -0
  1054. data/lib/fog/openstack/requests/network/disassociate_floating_ip.rb +47 -0
  1055. data/lib/fog/openstack/requests/network/disassociate_lb_health_monitor.rb +29 -0
  1056. data/lib/fog/openstack/requests/network/get_floating_ip.rb +39 -0
  1057. data/lib/fog/openstack/requests/network/get_lb_health_monitor.rb +28 -0
  1058. data/lib/fog/openstack/requests/network/get_lb_member.rb +28 -0
  1059. data/lib/fog/openstack/requests/network/get_lb_pool.rb +28 -0
  1060. data/lib/fog/openstack/requests/network/get_lb_pool_stats.rb +33 -0
  1061. data/lib/fog/openstack/requests/network/get_lb_vip.rb +28 -0
  1062. data/lib/fog/openstack/requests/network/get_network.rb +40 -0
  1063. data/lib/fog/openstack/requests/network/get_port.rb +51 -0
  1064. data/lib/fog/openstack/requests/network/get_quota.rb +26 -0
  1065. data/lib/fog/openstack/requests/network/get_quotas.rb +26 -0
  1066. data/lib/fog/openstack/requests/network/get_router.rb +30 -0
  1067. data/lib/fog/openstack/requests/network/get_security_group.rb +52 -0
  1068. data/lib/fog/openstack/requests/network/get_security_group_rule.rb +47 -0
  1069. data/lib/fog/openstack/requests/network/get_subnet.rb +47 -0
  1070. data/lib/fog/openstack/requests/network/list_floating_ips.rb +25 -0
  1071. data/lib/fog/openstack/requests/network/list_lb_health_monitors.rb +25 -0
  1072. data/lib/fog/openstack/requests/network/list_lb_members.rb +25 -0
  1073. data/lib/fog/openstack/requests/network/list_lb_pools.rb +25 -0
  1074. data/lib/fog/openstack/requests/network/list_lb_vips.rb +25 -0
  1075. data/lib/fog/openstack/requests/network/list_networks.rb +25 -0
  1076. data/lib/fog/openstack/requests/network/list_ports.rb +25 -0
  1077. data/lib/fog/openstack/requests/network/list_routers.rb +25 -0
  1078. data/lib/fog/openstack/requests/network/list_security_group_rules.rb +48 -0
  1079. data/lib/fog/openstack/requests/network/list_security_groups.rb +53 -0
  1080. data/lib/fog/openstack/requests/network/list_subnets.rb +25 -0
  1081. data/lib/fog/openstack/requests/network/remove_router_interface.rb +34 -0
  1082. data/lib/fog/openstack/requests/network/set_tenant.rb +20 -0
  1083. data/lib/fog/openstack/requests/network/update_lb_health_monitor.rb +43 -0
  1084. data/lib/fog/openstack/requests/network/update_lb_member.rb +39 -0
  1085. data/lib/fog/openstack/requests/network/update_lb_pool.rb +40 -0
  1086. data/lib/fog/openstack/requests/network/update_lb_vip.rb +42 -0
  1087. data/lib/fog/openstack/requests/network/update_network.rb +39 -0
  1088. data/lib/fog/openstack/requests/network/update_port.rb +43 -0
  1089. data/lib/fog/openstack/requests/network/update_quota.rb +27 -0
  1090. data/lib/fog/openstack/requests/network/update_router.rb +69 -0
  1091. data/lib/fog/openstack/requests/network/update_subnet.rb +43 -0
  1092. data/lib/fog/openstack/requests/orchestration/abandon_stack.rb +15 -0
  1093. data/lib/fog/openstack/requests/orchestration/build_info.rb +15 -0
  1094. data/lib/fog/openstack/requests/orchestration/create_stack.rb +75 -0
  1095. data/lib/fog/openstack/requests/orchestration/delete_stack.rb +58 -0
  1096. data/lib/fog/openstack/requests/orchestration/get_stack_template.rb +20 -0
  1097. data/lib/fog/openstack/requests/orchestration/list_events.rb +46 -0
  1098. data/lib/fog/openstack/requests/orchestration/list_resource_events.rb +28 -0
  1099. data/lib/fog/openstack/requests/orchestration/list_resource_types.rb +27 -0
  1100. data/lib/fog/openstack/requests/orchestration/list_resources.rb +46 -0
  1101. data/lib/fog/openstack/requests/orchestration/list_stack_data.rb +27 -0
  1102. data/lib/fog/openstack/requests/orchestration/list_stack_data_detailed.rb +49 -0
  1103. data/lib/fog/openstack/requests/orchestration/list_stack_events.rb +27 -0
  1104. data/lib/fog/openstack/requests/orchestration/patch_stack.rb +37 -0
  1105. data/lib/fog/openstack/requests/orchestration/preview_stack.rb +16 -0
  1106. data/lib/fog/openstack/requests/orchestration/show_event_details.rb +26 -0
  1107. data/lib/fog/openstack/requests/orchestration/show_resource_data.rb +26 -0
  1108. data/lib/fog/openstack/requests/orchestration/show_resource_metadata.rb +26 -0
  1109. data/lib/fog/openstack/requests/orchestration/show_resource_schema.rb +15 -0
  1110. data/lib/fog/openstack/requests/orchestration/show_resource_template.rb +20 -0
  1111. data/lib/fog/openstack/requests/orchestration/show_stack_details.rb +26 -0
  1112. data/lib/fog/openstack/requests/orchestration/update_stack.rb +66 -0
  1113. data/lib/fog/openstack/requests/orchestration/validate_template.rb +16 -0
  1114. data/lib/fog/openstack/requests/planning/add_role_to_plan.rb +40 -0
  1115. data/lib/fog/openstack/requests/planning/create_plan.rb +33 -0
  1116. data/lib/fog/openstack/requests/planning/delete_plan.rb +23 -0
  1117. data/lib/fog/openstack/requests/planning/get_plan.rb +58 -0
  1118. data/lib/fog/openstack/requests/planning/get_plan_templates.rb +28 -0
  1119. data/lib/fog/openstack/requests/planning/list_plans.rb +61 -0
  1120. data/lib/fog/openstack/requests/planning/list_roles.rb +32 -0
  1121. data/lib/fog/openstack/requests/planning/patch_plan.rb +51 -0
  1122. data/lib/fog/openstack/requests/planning/remove_role_from_plan.rb +32 -0
  1123. data/lib/fog/openstack/requests/storage/copy_object.rb +25 -0
  1124. data/lib/fog/openstack/requests/storage/delete_container.rb +20 -0
  1125. data/lib/fog/openstack/requests/storage/delete_multiple_objects.rb +65 -0
  1126. data/lib/fog/openstack/requests/storage/delete_object.rb +21 -0
  1127. data/lib/fog/openstack/requests/storage/delete_static_large_object.rb +41 -0
  1128. data/lib/fog/openstack/requests/storage/get_container.rb +42 -0
  1129. data/lib/fog/openstack/requests/storage/get_containers.rb +31 -0
  1130. data/lib/fog/openstack/requests/storage/get_object.rb +27 -0
  1131. data/lib/fog/openstack/requests/storage/get_object_http_url.rb +21 -0
  1132. data/lib/fog/openstack/requests/storage/get_object_https_url.rb +81 -0
  1133. data/lib/fog/openstack/requests/storage/head_container.rb +26 -0
  1134. data/lib/fog/openstack/requests/storage/head_containers.rb +23 -0
  1135. data/lib/fog/openstack/requests/storage/head_object.rb +21 -0
  1136. data/lib/fog/openstack/requests/storage/post_set_meta_temp_url_key.rb +33 -0
  1137. data/lib/fog/openstack/requests/storage/public_url.rb +28 -0
  1138. data/lib/fog/openstack/requests/storage/put_container.rb +24 -0
  1139. data/lib/fog/openstack/requests/storage/put_dynamic_obj_manifest.rb +41 -0
  1140. data/lib/fog/openstack/requests/storage/put_object.rb +41 -0
  1141. data/lib/fog/openstack/requests/storage/put_object_manifest.rb +14 -0
  1142. data/lib/fog/openstack/requests/storage/put_static_obj_manifest.rb +55 -0
  1143. data/lib/fog/openstack/requests/volume/accept_transfer.rb +24 -0
  1144. data/lib/fog/openstack/requests/volume/create_transfer.rb +27 -0
  1145. data/lib/fog/openstack/requests/volume/create_volume.rb +53 -0
  1146. data/lib/fog/openstack/requests/volume/create_volume_snapshot.rb +44 -0
  1147. data/lib/fog/openstack/requests/volume/create_volume_type.rb +41 -0
  1148. data/lib/fog/openstack/requests/volume/delete_snapshot.rb +23 -0
  1149. data/lib/fog/openstack/requests/volume/delete_transfer.rb +17 -0
  1150. data/lib/fog/openstack/requests/volume/delete_volume.rb +23 -0
  1151. data/lib/fog/openstack/requests/volume/delete_volume_type.rb +23 -0
  1152. data/lib/fog/openstack/requests/volume/extend_volume.rb +25 -0
  1153. data/lib/fog/openstack/requests/volume/get_quota.rb +26 -0
  1154. data/lib/fog/openstack/requests/volume/get_quota_defaults.rb +26 -0
  1155. data/lib/fog/openstack/requests/volume/get_snapshot_details.rb +34 -0
  1156. data/lib/fog/openstack/requests/volume/get_transfer_details.rb +17 -0
  1157. data/lib/fog/openstack/requests/volume/get_volume_details.rb +37 -0
  1158. data/lib/fog/openstack/requests/volume/get_volume_type_details.rb +32 -0
  1159. data/lib/fog/openstack/requests/volume/list_snapshots.rb +41 -0
  1160. data/lib/fog/openstack/requests/volume/list_snapshots_detailed.rb +27 -0
  1161. data/lib/fog/openstack/requests/volume/list_transfers.rb +18 -0
  1162. data/lib/fog/openstack/requests/volume/list_transfers_detailed.rb +18 -0
  1163. data/lib/fog/openstack/requests/volume/list_volume_types.rb +41 -0
  1164. data/lib/fog/openstack/requests/volume/list_volumes.rb +63 -0
  1165. data/lib/fog/openstack/requests/volume/list_volumes_detailed.rb +49 -0
  1166. data/lib/fog/openstack/requests/volume/list_zones.rb +32 -0
  1167. data/lib/fog/openstack/requests/volume/set_tenant.rb +19 -0
  1168. data/lib/fog/openstack/requests/volume/update_quota.rb +28 -0
  1169. data/lib/fog/openstack/requests/volume/update_volume_type.rb +41 -0
  1170. data/lib/fog/openstack/storage.rb +181 -0
  1171. data/lib/fog/openstack/volume.rb +184 -0
  1172. data/lib/fog/ovirt.rb +1 -0
  1173. data/lib/fog/ovirt/compute.rb +149 -0
  1174. data/lib/fog/ovirt/core.rb +16 -0
  1175. data/lib/fog/ovirt/models/compute/affinity_group.rb +25 -0
  1176. data/lib/fog/ovirt/models/compute/affinity_groups.rb +20 -0
  1177. data/lib/fog/ovirt/models/compute/cluster.rb +20 -0
  1178. data/lib/fog/ovirt/models/compute/clusters.rb +20 -0
  1179. data/lib/fog/ovirt/models/compute/interface.rb +19 -0
  1180. data/lib/fog/ovirt/models/compute/interfaces.rb +29 -0
  1181. data/lib/fog/ovirt/models/compute/quota.rb +16 -0
  1182. data/lib/fog/ovirt/models/compute/quotas.rb +20 -0
  1183. data/lib/fog/ovirt/models/compute/server.rb +169 -0
  1184. data/lib/fog/ovirt/models/compute/servers.rb +27 -0
  1185. data/lib/fog/ovirt/models/compute/template.rb +58 -0
  1186. data/lib/fog/ovirt/models/compute/templates.rb +20 -0
  1187. data/lib/fog/ovirt/models/compute/volume.rb +36 -0
  1188. data/lib/fog/ovirt/models/compute/volumes.rb +28 -0
  1189. data/lib/fog/ovirt/requests/compute/add_interface.rb +20 -0
  1190. data/lib/fog/ovirt/requests/compute/add_to_affinity_group.rb +21 -0
  1191. data/lib/fog/ovirt/requests/compute/add_volume.rb +21 -0
  1192. data/lib/fog/ovirt/requests/compute/{activate_volume.rb → attach_volume.rb} +5 -5
  1193. data/lib/fog/ovirt/requests/compute/create_affinity_group.rb +18 -0
  1194. data/lib/fog/ovirt/requests/compute/create_vm.rb +18 -0
  1195. data/lib/fog/ovirt/requests/compute/datacenters.rb +20 -0
  1196. data/lib/fog/ovirt/requests/compute/destroy_affinity_group.rb +19 -0
  1197. data/lib/fog/ovirt/requests/compute/destroy_interface.rb +22 -0
  1198. data/lib/fog/ovirt/requests/compute/destroy_vm.rb +19 -0
  1199. data/lib/fog/ovirt/requests/compute/{deactivate_volume.rb → destroy_volume.rb} +5 -5
  1200. data/lib/fog/ovirt/requests/compute/detach_volume.rb +22 -0
  1201. data/lib/fog/ovirt/requests/compute/get_affinity_group.rb +18 -0
  1202. data/lib/fog/ovirt/requests/compute/get_api_version.rb +16 -0
  1203. data/lib/fog/ovirt/requests/compute/get_cluster.rb +17 -0
  1204. data/lib/fog/ovirt/requests/compute/get_quota.rb +17 -0
  1205. data/lib/fog/ovirt/requests/compute/get_template.rb +17 -0
  1206. data/lib/fog/ovirt/requests/compute/get_virtual_machine.rb +17 -0
  1207. data/lib/fog/ovirt/requests/compute/list_affinity_group_vms.rb +22 -0
  1208. data/lib/fog/ovirt/requests/compute/list_affinity_groups.rb +20 -0
  1209. data/lib/fog/ovirt/requests/compute/list_clusters.rb +19 -0
  1210. data/lib/fog/ovirt/requests/compute/list_networks.rb +16 -0
  1211. data/lib/fog/ovirt/requests/compute/list_quotas.rb +19 -0
  1212. data/lib/fog/ovirt/requests/compute/list_template_interfaces.rb +19 -0
  1213. data/lib/fog/ovirt/requests/compute/list_template_volumes.rb +19 -0
  1214. data/lib/fog/ovirt/requests/compute/list_templates.rb +19 -0
  1215. data/lib/fog/ovirt/requests/compute/list_virtual_machines.rb +19 -0
  1216. data/lib/fog/ovirt/requests/compute/list_vm_interfaces.rb +19 -0
  1217. data/lib/fog/ovirt/requests/compute/list_vm_volumes.rb +19 -0
  1218. data/lib/fog/ovirt/requests/compute/list_volumes.rb +19 -0
  1219. data/lib/fog/ovirt/requests/compute/mock_files/affinitygroup.xml +8 -0
  1220. data/lib/fog/ovirt/requests/compute/mock_files/affinitygroup_vms.xml +9 -0
  1221. data/lib/fog/ovirt/requests/compute/mock_files/affinitygroups.xml +17 -0
  1222. data/lib/fog/ovirt/requests/compute/mock_files/cluster.xml +20 -0
  1223. data/lib/fog/ovirt/requests/compute/mock_files/clusters.xml +39 -0
  1224. data/lib/fog/ovirt/requests/compute/mock_files/data_centers.xml +17 -0
  1225. data/lib/fog/ovirt/requests/compute/mock_files/disks.xml +58 -0
  1226. data/lib/fog/ovirt/requests/compute/mock_files/nics.xml +10 -0
  1227. data/lib/fog/ovirt/requests/compute/mock_files/quotas.xml +7 -0
  1228. data/lib/fog/ovirt/requests/compute/mock_files/storage_domains.xml +36 -0
  1229. data/lib/fog/ovirt/requests/compute/mock_files/template.xml +39 -0
  1230. data/lib/fog/ovirt/requests/compute/mock_files/templates.xml +110 -0
  1231. data/lib/fog/ovirt/requests/compute/mock_files/vm.xml +52 -0
  1232. data/lib/fog/ovirt/requests/compute/mock_files/vms.xml +152 -0
  1233. data/lib/fog/ovirt/requests/compute/mock_files/volumes.xml +40 -0
  1234. data/lib/fog/ovirt/requests/compute/remove_from_affinity_group.rb +21 -0
  1235. data/lib/fog/ovirt/requests/compute/storage_domains.rb +20 -0
  1236. data/lib/fog/ovirt/requests/compute/update_interface.rb +35 -0
  1237. data/lib/fog/ovirt/requests/compute/update_vm.rb +18 -0
  1238. data/lib/fog/ovirt/requests/compute/update_volume.rb +39 -0
  1239. data/lib/fog/ovirt/requests/compute/vm_action.rb +22 -0
  1240. data/lib/fog/ovirt/requests/compute/vm_start_with_cloudinit.rb +19 -0
  1241. data/lib/fog/ovirt/requests/compute/vm_ticket.rb +17 -0
  1242. data/lib/fog/rackspace.rb +16 -0
  1243. data/lib/fog/rackspace/auto_scale.rb +134 -0
  1244. data/lib/fog/rackspace/block_storage.rb +175 -0
  1245. data/lib/fog/rackspace/cdn.rb +198 -0
  1246. data/lib/fog/rackspace/cdn_v2.rb +123 -0
  1247. data/lib/fog/rackspace/compute.rb +256 -0
  1248. data/lib/fog/rackspace/compute_v2.rb +250 -0
  1249. data/lib/fog/rackspace/core.rb +150 -0
  1250. data/lib/fog/rackspace/databases.rb +164 -0
  1251. data/lib/fog/rackspace/dns.rb +172 -0
  1252. data/lib/fog/rackspace/docs/auto_scale.md +503 -0
  1253. data/lib/fog/rackspace/docs/block_storage.md +417 -0
  1254. data/lib/fog/rackspace/docs/cdn_v2.md +351 -0
  1255. data/lib/fog/rackspace/docs/compute_v2.md +723 -0
  1256. data/lib/fog/rackspace/docs/getting_started.md +88 -0
  1257. data/lib/fog/rackspace/docs/networking_v2.md +422 -0
  1258. data/lib/fog/rackspace/docs/orchestration.md +356 -0
  1259. data/lib/fog/rackspace/docs/queues.md +312 -0
  1260. data/lib/fog/rackspace/docs/storage.md +557 -0
  1261. data/lib/fog/rackspace/errors.rb +33 -0
  1262. data/lib/fog/rackspace/examples/README.md +47 -0
  1263. data/lib/fog/rackspace/examples/auto_scale/add_policy.rb +66 -0
  1264. data/lib/fog/rackspace/examples/auto_scale/add_webhook.rb +74 -0
  1265. data/lib/fog/rackspace/examples/auto_scale/create_scaling_group.rb +111 -0
  1266. data/lib/fog/rackspace/examples/auto_scale/delete_policy.rb +71 -0
  1267. data/lib/fog/rackspace/examples/auto_scale/delete_scaling_group.rb +59 -0
  1268. data/lib/fog/rackspace/examples/auto_scale/delete_webhook.rb +89 -0
  1269. data/lib/fog/rackspace/examples/block_storage/create_snapshot.rb +116 -0
  1270. data/lib/fog/rackspace/examples/block_storage/create_volume.rb +58 -0
  1271. data/lib/fog/rackspace/examples/block_storage/delete_volume.rb +53 -0
  1272. data/lib/fog/rackspace/examples/compute_v2/bootstrap_server.rb +96 -0
  1273. data/lib/fog/rackspace/examples/compute_v2/create_image.rb +59 -0
  1274. data/lib/fog/rackspace/examples/compute_v2/create_network.rb +81 -0
  1275. data/lib/fog/rackspace/examples/compute_v2/create_server.rb +87 -0
  1276. data/lib/fog/rackspace/examples/compute_v2/delete_image.rb +60 -0
  1277. data/lib/fog/rackspace/examples/compute_v2/delete_network.rb +78 -0
  1278. data/lib/fog/rackspace/examples/compute_v2/delete_server.rb +55 -0
  1279. data/lib/fog/rackspace/examples/compute_v2/detach_volume.rb +93 -0
  1280. data/lib/fog/rackspace/examples/compute_v2/resize_server.rb +106 -0
  1281. data/lib/fog/rackspace/examples/compute_v2/server_attachments.rb +68 -0
  1282. data/lib/fog/rackspace/examples/compute_v2/server_metadata.rb +83 -0
  1283. data/lib/fog/rackspace/examples/queues/claim_messages.rb +60 -0
  1284. data/lib/fog/rackspace/examples/queues/create_queue.rb +45 -0
  1285. data/lib/fog/rackspace/examples/queues/delete_message.rb +71 -0
  1286. data/lib/fog/rackspace/examples/queues/delete_queue.rb +53 -0
  1287. data/lib/fog/rackspace/examples/queues/list_messages.rb +64 -0
  1288. data/lib/fog/rackspace/examples/queues/post_message.rb +59 -0
  1289. data/lib/fog/rackspace/examples/storage/create_cdn_directory.rb +43 -0
  1290. data/lib/fog/rackspace/examples/storage/create_private_directory.rb +43 -0
  1291. data/lib/fog/rackspace/examples/storage/delete_directory.rb +62 -0
  1292. data/lib/fog/rackspace/examples/storage/delete_file.rb +70 -0
  1293. data/lib/fog/rackspace/examples/storage/download_file.rb +75 -0
  1294. data/lib/fog/rackspace/examples/storage/lorem.txt +1 -0
  1295. data/lib/fog/rackspace/examples/storage/storage_metadata.rb +76 -0
  1296. data/lib/fog/rackspace/examples/storage/upload_file.rb +44 -0
  1297. data/lib/fog/rackspace/examples/storage/upload_large_files.rb +101 -0
  1298. data/lib/fog/rackspace/identity.rb +83 -0
  1299. data/lib/fog/rackspace/load_balancers.rb +206 -0
  1300. data/lib/fog/rackspace/mock_data.rb +252 -0
  1301. data/lib/fog/rackspace/models/auto_scale/group.rb +214 -0
  1302. data/lib/fog/rackspace/models/auto_scale/group_builder.rb +86 -0
  1303. data/lib/fog/rackspace/models/auto_scale/group_config.rb +76 -0
  1304. data/lib/fog/rackspace/models/auto_scale/groups.rb +45 -0
  1305. data/lib/fog/rackspace/models/auto_scale/launch_config.rb +61 -0
  1306. data/lib/fog/rackspace/models/auto_scale/policies.rb +65 -0
  1307. data/lib/fog/rackspace/models/auto_scale/policy.rb +220 -0
  1308. data/lib/fog/rackspace/models/auto_scale/webhook.rb +116 -0
  1309. data/lib/fog/rackspace/models/auto_scale/webhooks.rb +62 -0
  1310. data/lib/fog/rackspace/models/block_storage/snapshot.rb +93 -0
  1311. data/lib/fog/rackspace/models/block_storage/snapshots.rb +39 -0
  1312. data/lib/fog/rackspace/models/block_storage/volume.rb +134 -0
  1313. data/lib/fog/rackspace/models/block_storage/volume_type.rb +19 -0
  1314. data/lib/fog/rackspace/models/block_storage/volume_types.rb +39 -0
  1315. data/lib/fog/rackspace/models/block_storage/volumes.rb +39 -0
  1316. data/lib/fog/rackspace/models/cdn_v2/flavor.rb +14 -0
  1317. data/lib/fog/rackspace/models/cdn_v2/flavors.rb +24 -0
  1318. data/lib/fog/rackspace/models/cdn_v2/service.rb +66 -0
  1319. data/lib/fog/rackspace/models/cdn_v2/services.rb +24 -0
  1320. data/lib/fog/rackspace/models/compute/flavor.rb +42 -0
  1321. data/lib/fog/rackspace/models/compute/flavors.rb +24 -0
  1322. data/lib/fog/rackspace/models/compute/image.rb +44 -0
  1323. data/lib/fog/rackspace/models/compute/images.rb +31 -0
  1324. data/lib/fog/rackspace/models/compute/server.rb +102 -0
  1325. data/lib/fog/rackspace/models/compute/servers.rb +32 -0
  1326. data/lib/fog/rackspace/models/compute_v2/attachment.rb +61 -0
  1327. data/lib/fog/rackspace/models/compute_v2/attachments.rb +38 -0
  1328. data/lib/fog/rackspace/models/compute_v2/flavor.rb +33 -0
  1329. data/lib/fog/rackspace/models/compute_v2/flavors.rb +39 -0
  1330. data/lib/fog/rackspace/models/compute_v2/image.rb +117 -0
  1331. data/lib/fog/rackspace/models/compute_v2/images.rb +73 -0
  1332. data/lib/fog/rackspace/models/compute_v2/key_pair.rb +54 -0
  1333. data/lib/fog/rackspace/models/compute_v2/key_pairs.rb +40 -0
  1334. data/lib/fog/rackspace/models/compute_v2/meta_parent.rb +40 -0
  1335. data/lib/fog/rackspace/models/compute_v2/metadata.rb +108 -0
  1336. data/lib/fog/rackspace/models/compute_v2/metadatum.rb +39 -0
  1337. data/lib/fog/rackspace/models/compute_v2/network.rb +27 -0
  1338. data/lib/fog/rackspace/models/compute_v2/networks.rb +23 -0
  1339. data/lib/fog/rackspace/models/compute_v2/server.rb +631 -0
  1340. data/lib/fog/rackspace/models/compute_v2/servers.rb +64 -0
  1341. data/lib/fog/rackspace/models/compute_v2/virtual_interface.rb +85 -0
  1342. data/lib/fog/rackspace/models/compute_v2/virtual_interfaces.rb +46 -0
  1343. data/lib/fog/rackspace/models/databases/database.rb +43 -0
  1344. data/lib/fog/rackspace/models/databases/databases.rb +30 -0
  1345. data/lib/fog/rackspace/models/databases/flavor.rb +15 -0
  1346. data/lib/fog/rackspace/models/databases/flavors.rb +24 -0
  1347. data/lib/fog/rackspace/models/databases/instance.rb +104 -0
  1348. data/lib/fog/rackspace/models/databases/instances.rb +24 -0
  1349. data/lib/fog/rackspace/models/databases/user.rb +33 -0
  1350. data/lib/fog/rackspace/models/databases/users.rb +30 -0
  1351. data/lib/fog/rackspace/models/dns/callback.rb +28 -0
  1352. data/lib/fog/rackspace/models/dns/record.rb +98 -0
  1353. data/lib/fog/rackspace/models/dns/records.rb +58 -0
  1354. data/lib/fog/rackspace/models/dns/zone.rb +66 -0
  1355. data/lib/fog/rackspace/models/dns/zones.rb +74 -0
  1356. data/lib/fog/rackspace/models/identity/credential.rb +13 -0
  1357. data/lib/fog/rackspace/models/identity/credentials.rb +32 -0
  1358. data/lib/fog/rackspace/models/identity/role.rb +14 -0
  1359. data/lib/fog/rackspace/models/identity/roles.rb +31 -0
  1360. data/lib/fog/rackspace/models/identity/service_catalog.rb +84 -0
  1361. data/lib/fog/rackspace/models/identity/tenant.rb +15 -0
  1362. data/lib/fog/rackspace/models/identity/tenants.rb +27 -0
  1363. data/lib/fog/rackspace/models/identity/user.rb +53 -0
  1364. data/lib/fog/rackspace/models/identity/users.rb +35 -0
  1365. data/lib/fog/rackspace/models/load_balancers/access_rule.rb +38 -0
  1366. data/lib/fog/rackspace/models/load_balancers/access_rules.rb +29 -0
  1367. data/lib/fog/rackspace/models/load_balancers/load_balancer.rb +286 -0
  1368. data/lib/fog/rackspace/models/load_balancers/load_balancers.rb +25 -0
  1369. data/lib/fog/rackspace/models/load_balancers/node.rb +65 -0
  1370. data/lib/fog/rackspace/models/load_balancers/nodes.rb +29 -0
  1371. data/lib/fog/rackspace/models/load_balancers/virtual_ip.rb +34 -0
  1372. data/lib/fog/rackspace/models/load_balancers/virtual_ips.rb +32 -0
  1373. data/lib/fog/rackspace/models/monitoring/agent_token.rb +38 -0
  1374. data/lib/fog/rackspace/models/monitoring/agent_tokens.rb +29 -0
  1375. data/lib/fog/rackspace/models/monitoring/alarm.rb +58 -0
  1376. data/lib/fog/rackspace/models/monitoring/alarm_example.rb +24 -0
  1377. data/lib/fog/rackspace/models/monitoring/alarm_examples.rb +29 -0
  1378. data/lib/fog/rackspace/models/monitoring/alarms.rb +41 -0
  1379. data/lib/fog/rackspace/models/monitoring/base.rb +29 -0
  1380. data/lib/fog/rackspace/models/monitoring/check.rb +72 -0
  1381. data/lib/fog/rackspace/models/monitoring/check_type.rb +15 -0
  1382. data/lib/fog/rackspace/models/monitoring/check_types.rb +21 -0
  1383. data/lib/fog/rackspace/models/monitoring/checks.rb +41 -0
  1384. data/lib/fog/rackspace/models/monitoring/data_point.rb +18 -0
  1385. data/lib/fog/rackspace/models/monitoring/data_points.rb +47 -0
  1386. data/lib/fog/rackspace/models/monitoring/entities.rb +47 -0
  1387. data/lib/fog/rackspace/models/monitoring/entity.rb +62 -0
  1388. data/lib/fog/rackspace/models/monitoring/metric.rb +22 -0
  1389. data/lib/fog/rackspace/models/monitoring/metrics.rb +25 -0
  1390. data/lib/fog/rackspace/models/monitoring/notification.rb +40 -0
  1391. data/lib/fog/rackspace/models/monitoring/notifications.rb +28 -0
  1392. data/lib/fog/rackspace/models/networking/network.rb +27 -0
  1393. data/lib/fog/rackspace/models/networking/networks.rb +23 -0
  1394. data/lib/fog/rackspace/models/networking/virtual_interface.rb +85 -0
  1395. data/lib/fog/rackspace/models/networking/virtual_interfaces.rb +45 -0
  1396. data/lib/fog/rackspace/models/networking_v2/network.rb +36 -0
  1397. data/lib/fog/rackspace/models/networking_v2/networks.rb +23 -0
  1398. data/lib/fog/rackspace/models/networking_v2/port.rb +39 -0
  1399. data/lib/fog/rackspace/models/networking_v2/ports.rb +23 -0
  1400. data/lib/fog/rackspace/models/networking_v2/security_group.rb +32 -0
  1401. data/lib/fog/rackspace/models/networking_v2/security_group_rule.rb +38 -0
  1402. data/lib/fog/rackspace/models/networking_v2/security_group_rules.rb +23 -0
  1403. data/lib/fog/rackspace/models/networking_v2/security_groups.rb +23 -0
  1404. data/lib/fog/rackspace/models/networking_v2/subnet.rb +38 -0
  1405. data/lib/fog/rackspace/models/networking_v2/subnets.rb +23 -0
  1406. data/lib/fog/rackspace/models/orchestration/event.rb +18 -0
  1407. data/lib/fog/rackspace/models/orchestration/events.rb +28 -0
  1408. data/lib/fog/rackspace/models/orchestration/resource.rb +30 -0
  1409. data/lib/fog/rackspace/models/orchestration/resource_schemas.rb +16 -0
  1410. data/lib/fog/rackspace/models/orchestration/resources.rb +35 -0
  1411. data/lib/fog/rackspace/models/orchestration/stack.rb +48 -0
  1412. data/lib/fog/rackspace/models/orchestration/stacks.rb +40 -0
  1413. data/lib/fog/rackspace/models/orchestration/template.rb +13 -0
  1414. data/lib/fog/rackspace/models/orchestration/templates.rb +31 -0
  1415. data/lib/fog/rackspace/models/queues/claim.rb +139 -0
  1416. data/lib/fog/rackspace/models/queues/claims.rb +64 -0
  1417. data/lib/fog/rackspace/models/queues/message.rb +88 -0
  1418. data/lib/fog/rackspace/models/queues/messages.rb +90 -0
  1419. data/lib/fog/rackspace/models/queues/queue.rb +135 -0
  1420. data/lib/fog/rackspace/models/queues/queues.rb +46 -0
  1421. data/lib/fog/rackspace/models/storage/account.rb +50 -0
  1422. data/lib/fog/rackspace/models/storage/directories.rb +62 -0
  1423. data/lib/fog/rackspace/models/storage/directory.rb +194 -0
  1424. data/lib/fog/rackspace/models/storage/file.rb +286 -0
  1425. data/lib/fog/rackspace/models/storage/files.rb +201 -0
  1426. data/lib/fog/rackspace/models/storage/metadata.rb +165 -0
  1427. data/lib/fog/rackspace/monitoring.rb +184 -0
  1428. data/lib/fog/rackspace/networking.rb +192 -0
  1429. data/lib/fog/rackspace/networking_v2.rb +222 -0
  1430. data/lib/fog/rackspace/orchestration.rb +227 -0
  1431. data/lib/fog/rackspace/queues.rb +406 -0
  1432. data/lib/fog/rackspace/requests/auto_scale/create_group.rb +58 -0
  1433. data/lib/fog/rackspace/requests/auto_scale/create_policy.rb +42 -0
  1434. data/lib/fog/rackspace/requests/auto_scale/create_webhook.rb +54 -0
  1435. data/lib/fog/rackspace/requests/auto_scale/delete_group.rb +22 -0
  1436. data/lib/fog/rackspace/requests/auto_scale/delete_policy.rb +29 -0
  1437. data/lib/fog/rackspace/requests/auto_scale/delete_webhook.rb +33 -0
  1438. data/lib/fog/rackspace/requests/auto_scale/execute_anonymous_webhook.rb +21 -0
  1439. data/lib/fog/rackspace/requests/auto_scale/execute_policy.rb +21 -0
  1440. data/lib/fog/rackspace/requests/auto_scale/get_group.rb +26 -0
  1441. data/lib/fog/rackspace/requests/auto_scale/get_group_config.rb +27 -0
  1442. data/lib/fog/rackspace/requests/auto_scale/get_group_state.rb +58 -0
  1443. data/lib/fog/rackspace/requests/auto_scale/get_launch_config.rb +27 -0
  1444. data/lib/fog/rackspace/requests/auto_scale/get_policy.rb +31 -0
  1445. data/lib/fog/rackspace/requests/auto_scale/get_webhook.rb +36 -0
  1446. data/lib/fog/rackspace/requests/auto_scale/list_groups.rb +34 -0
  1447. data/lib/fog/rackspace/requests/auto_scale/list_policies.rb +22 -0
  1448. data/lib/fog/rackspace/requests/auto_scale/list_webhooks.rb +31 -0
  1449. data/lib/fog/rackspace/requests/auto_scale/pause_group_state.rb +22 -0
  1450. data/lib/fog/rackspace/requests/auto_scale/resume_group_state.rb +21 -0
  1451. data/lib/fog/rackspace/requests/auto_scale/update_group_config.rb +37 -0
  1452. data/lib/fog/rackspace/requests/auto_scale/update_launch_config.rb +34 -0
  1453. data/lib/fog/rackspace/requests/auto_scale/update_policy.rb +31 -0
  1454. data/lib/fog/rackspace/requests/auto_scale/update_webhook.rb +41 -0
  1455. data/lib/fog/rackspace/requests/block_storage/create_snapshot.rb +77 -0
  1456. data/lib/fog/rackspace/requests/block_storage/create_volume.rb +96 -0
  1457. data/lib/fog/rackspace/requests/block_storage/delete_snapshot.rb +31 -0
  1458. data/lib/fog/rackspace/requests/block_storage/delete_volume.rb +42 -0
  1459. data/lib/fog/rackspace/requests/block_storage/get_snapshot.rb +45 -0
  1460. data/lib/fog/rackspace/requests/block_storage/get_volume.rb +55 -0
  1461. data/lib/fog/rackspace/requests/block_storage/get_volume_type.rb +41 -0
  1462. data/lib/fog/rackspace/requests/block_storage/list_snapshots.rb +39 -0
  1463. data/lib/fog/rackspace/requests/block_storage/list_volume_types.rb +34 -0
  1464. data/lib/fog/rackspace/requests/block_storage/list_volumes.rb +42 -0
  1465. data/lib/fog/rackspace/requests/cdn/delete_object.rb +39 -0
  1466. data/lib/fog/rackspace/requests/cdn/get_containers.rb +66 -0
  1467. data/lib/fog/rackspace/requests/cdn/head_container.rb +58 -0
  1468. data/lib/fog/rackspace/requests/cdn/post_container.rb +52 -0
  1469. data/lib/fog/rackspace/requests/cdn/put_container.rb +52 -0
  1470. data/lib/fog/rackspace/requests/cdn_v2/create_service.rb +10 -0
  1471. data/lib/fog/rackspace/requests/cdn_v2/delete_assets.rb +12 -0
  1472. data/lib/fog/rackspace/requests/cdn_v2/delete_service.rb +9 -0
  1473. data/lib/fog/rackspace/requests/cdn_v2/get_flavor.rb +9 -0
  1474. data/lib/fog/rackspace/requests/cdn_v2/get_home_document.rb +9 -0
  1475. data/lib/fog/rackspace/requests/cdn_v2/get_ping.rb +10 -0
  1476. data/lib/fog/rackspace/requests/cdn_v2/get_service.rb +9 -0
  1477. data/lib/fog/rackspace/requests/cdn_v2/list_flavors.rb +9 -0
  1478. data/lib/fog/rackspace/requests/cdn_v2/list_services.rb +9 -0
  1479. data/lib/fog/rackspace/requests/cdn_v2/update_service.rb +13 -0
  1480. data/lib/fog/rackspace/requests/compute/confirm_resized_server.rb +30 -0
  1481. data/lib/fog/rackspace/requests/compute/create_image.rb +56 -0
  1482. data/lib/fog/rackspace/requests/compute/create_server.rb +90 -0
  1483. data/lib/fog/rackspace/requests/compute/delete_image.rb +40 -0
  1484. data/lib/fog/rackspace/requests/compute/delete_server.rb +39 -0
  1485. data/lib/fog/rackspace/requests/compute/get_flavor_details.rb +48 -0
  1486. data/lib/fog/rackspace/requests/compute/get_image_details.rb +25 -0
  1487. data/lib/fog/rackspace/requests/compute/get_server_details.rb +48 -0
  1488. data/lib/fog/rackspace/requests/compute/list_addresses.rb +39 -0
  1489. data/lib/fog/rackspace/requests/compute/list_flavors.rb +41 -0
  1490. data/lib/fog/rackspace/requests/compute/list_flavors_detail.rb +43 -0
  1491. data/lib/fog/rackspace/requests/compute/list_images.rb +36 -0
  1492. data/lib/fog/rackspace/requests/compute/list_images_detail.rb +45 -0
  1493. data/lib/fog/rackspace/requests/compute/list_private_addresses.rb +37 -0
  1494. data/lib/fog/rackspace/requests/compute/list_public_addresses.rb +37 -0
  1495. data/lib/fog/rackspace/requests/compute/list_servers.rb +37 -0
  1496. data/lib/fog/rackspace/requests/compute/list_servers_detail.rb +52 -0
  1497. data/lib/fog/rackspace/requests/compute/reboot_server.rb +26 -0
  1498. data/lib/fog/rackspace/requests/compute/resize_server.rb +35 -0
  1499. data/lib/fog/rackspace/requests/compute/revert_resized_server.rb +31 -0
  1500. data/lib/fog/rackspace/requests/compute/server_action.rb +23 -0
  1501. data/lib/fog/rackspace/requests/compute/update_server.rb +41 -0
  1502. data/lib/fog/rackspace/requests/compute_v2/attach_volume.rb +78 -0
  1503. data/lib/fog/rackspace/requests/compute_v2/change_server_password.rb +38 -0
  1504. data/lib/fog/rackspace/requests/compute_v2/confirm_resize_server.rb +41 -0
  1505. data/lib/fog/rackspace/requests/compute_v2/create_image.rb +97 -0
  1506. data/lib/fog/rackspace/requests/compute_v2/create_keypair.rb +62 -0
  1507. data/lib/fog/rackspace/requests/compute_v2/create_network.rb +36 -0
  1508. data/lib/fog/rackspace/requests/compute_v2/create_server.rb +238 -0
  1509. data/lib/fog/rackspace/requests/compute_v2/create_virtual_interface.rb +30 -0
  1510. data/lib/fog/rackspace/requests/compute_v2/delete_attachment.rb +39 -0
  1511. data/lib/fog/rackspace/requests/compute_v2/delete_image.rb +32 -0
  1512. data/lib/fog/rackspace/requests/compute_v2/delete_keypair.rb +34 -0
  1513. data/lib/fog/rackspace/requests/compute_v2/delete_metadata_item.rb +36 -0
  1514. data/lib/fog/rackspace/requests/compute_v2/delete_network.rb +21 -0
  1515. data/lib/fog/rackspace/requests/compute_v2/delete_server.rb +35 -0
  1516. data/lib/fog/rackspace/requests/compute_v2/delete_virtual_interface.rb +23 -0
  1517. data/lib/fog/rackspace/requests/compute_v2/get_attachment.rb +38 -0
  1518. data/lib/fog/rackspace/requests/compute_v2/get_flavor.rb +43 -0
  1519. data/lib/fog/rackspace/requests/compute_v2/get_image.rb +47 -0
  1520. data/lib/fog/rackspace/requests/compute_v2/get_keypair.rb +39 -0
  1521. data/lib/fog/rackspace/requests/compute_v2/get_metadata_item.rb +38 -0
  1522. data/lib/fog/rackspace/requests/compute_v2/get_network.rb +21 -0
  1523. data/lib/fog/rackspace/requests/compute_v2/get_server.rb +63 -0
  1524. data/lib/fog/rackspace/requests/compute_v2/list_addresses.rb +39 -0
  1525. data/lib/fog/rackspace/requests/compute_v2/list_addresses_by_network.rb +48 -0
  1526. data/lib/fog/rackspace/requests/compute_v2/list_attachments.rb +37 -0
  1527. data/lib/fog/rackspace/requests/compute_v2/list_flavors.rb +35 -0
  1528. data/lib/fog/rackspace/requests/compute_v2/list_flavors_detail.rb +38 -0
  1529. data/lib/fog/rackspace/requests/compute_v2/list_images.rb +45 -0
  1530. data/lib/fog/rackspace/requests/compute_v2/list_images_detail.rb +52 -0
  1531. data/lib/fog/rackspace/requests/compute_v2/list_keypairs.rb +35 -0
  1532. data/lib/fog/rackspace/requests/compute_v2/list_metadata.rb +37 -0
  1533. data/lib/fog/rackspace/requests/compute_v2/list_networks.rb +18 -0
  1534. data/lib/fog/rackspace/requests/compute_v2/list_servers.rb +56 -0
  1535. data/lib/fog/rackspace/requests/compute_v2/list_virtual_interfaces.rb +22 -0
  1536. data/lib/fog/rackspace/requests/compute_v2/reboot_server.rb +44 -0
  1537. data/lib/fog/rackspace/requests/compute_v2/rebuild_server.rb +71 -0
  1538. data/lib/fog/rackspace/requests/compute_v2/rescue_server.rb +43 -0
  1539. data/lib/fog/rackspace/requests/compute_v2/resize_server.rb +44 -0
  1540. data/lib/fog/rackspace/requests/compute_v2/revert_resize_server.rb +42 -0
  1541. data/lib/fog/rackspace/requests/compute_v2/set_metadata.rb +39 -0
  1542. data/lib/fog/rackspace/requests/compute_v2/set_metadata_item.rb +40 -0
  1543. data/lib/fog/rackspace/requests/compute_v2/unrescue_server.rb +40 -0
  1544. data/lib/fog/rackspace/requests/compute_v2/update_metadata.rb +39 -0
  1545. data/lib/fog/rackspace/requests/compute_v2/update_server.rb +44 -0
  1546. data/lib/fog/rackspace/requests/databases/check_root_user.rb +15 -0
  1547. data/lib/fog/rackspace/requests/databases/create_database.rb +24 -0
  1548. data/lib/fog/rackspace/requests/databases/create_instance.rb +28 -0
  1549. data/lib/fog/rackspace/requests/databases/create_user.rb +25 -0
  1550. data/lib/fog/rackspace/requests/databases/delete_database.rb +15 -0
  1551. data/lib/fog/rackspace/requests/databases/delete_instance.rb +15 -0
  1552. data/lib/fog/rackspace/requests/databases/delete_user.rb +15 -0
  1553. data/lib/fog/rackspace/requests/databases/enable_root_user.rb +15 -0
  1554. data/lib/fog/rackspace/requests/databases/get_flavor.rb +15 -0
  1555. data/lib/fog/rackspace/requests/databases/get_instance.rb +15 -0
  1556. data/lib/fog/rackspace/requests/databases/grant_user_access.rb +32 -0
  1557. data/lib/fog/rackspace/requests/databases/list_databases.rb +15 -0
  1558. data/lib/fog/rackspace/requests/databases/list_flavors.rb +15 -0
  1559. data/lib/fog/rackspace/requests/databases/list_instances.rb +15 -0
  1560. data/lib/fog/rackspace/requests/databases/list_users.rb +15 -0
  1561. data/lib/fog/rackspace/requests/databases/resize_instance.rb +22 -0
  1562. data/lib/fog/rackspace/requests/databases/resize_instance_volume.rb +24 -0
  1563. data/lib/fog/rackspace/requests/databases/restart_instance.rb +20 -0
  1564. data/lib/fog/rackspace/requests/databases/revoke_user_access.rb +26 -0
  1565. data/lib/fog/rackspace/requests/dns/add_records.rb +37 -0
  1566. data/lib/fog/rackspace/requests/dns/callback.rb +18 -0
  1567. data/lib/fog/rackspace/requests/dns/create_domains.rb +48 -0
  1568. data/lib/fog/rackspace/requests/dns/list_domain_details.rb +31 -0
  1569. data/lib/fog/rackspace/requests/dns/list_domains.rb +20 -0
  1570. data/lib/fog/rackspace/requests/dns/list_record_details.rb +20 -0
  1571. data/lib/fog/rackspace/requests/dns/list_records.rb +22 -0
  1572. data/lib/fog/rackspace/requests/dns/list_subdomains.rb +22 -0
  1573. data/lib/fog/rackspace/requests/dns/modify_domain.rb +35 -0
  1574. data/lib/fog/rackspace/requests/dns/modify_record.rb +36 -0
  1575. data/lib/fog/rackspace/requests/dns/remove_domain.rb +28 -0
  1576. data/lib/fog/rackspace/requests/dns/remove_domains.rb +26 -0
  1577. data/lib/fog/rackspace/requests/dns/remove_record.rb +20 -0
  1578. data/lib/fog/rackspace/requests/dns/remove_records.rb +19 -0
  1579. data/lib/fog/rackspace/requests/identity/create_token.rb +222 -0
  1580. data/lib/fog/rackspace/requests/identity/create_user.rb +25 -0
  1581. data/lib/fog/rackspace/requests/identity/delete_user.rb +15 -0
  1582. data/lib/fog/rackspace/requests/identity/get_user_by_id.rb +15 -0
  1583. data/lib/fog/rackspace/requests/identity/get_user_by_name.rb +15 -0
  1584. data/lib/fog/rackspace/requests/identity/list_credentials.rb +22 -0
  1585. data/lib/fog/rackspace/requests/identity/list_tenants.rb +45 -0
  1586. data/lib/fog/rackspace/requests/identity/list_user_roles.rb +22 -0
  1587. data/lib/fog/rackspace/requests/identity/list_users.rb +22 -0
  1588. data/lib/fog/rackspace/requests/identity/update_user.rb +24 -0
  1589. data/lib/fog/rackspace/requests/load_balancers/create_access_rule.rb +24 -0
  1590. data/lib/fog/rackspace/requests/load_balancers/create_load_balancer.rb +109 -0
  1591. data/lib/fog/rackspace/requests/load_balancers/create_node.rb +30 -0
  1592. data/lib/fog/rackspace/requests/load_balancers/create_virtual_ip.rb +20 -0
  1593. data/lib/fog/rackspace/requests/load_balancers/delete_access_rule.rb +15 -0
  1594. data/lib/fog/rackspace/requests/load_balancers/delete_all_access_rules.rb +15 -0
  1595. data/lib/fog/rackspace/requests/load_balancers/delete_load_balancer.rb +23 -0
  1596. data/lib/fog/rackspace/requests/load_balancers/delete_node.rb +15 -0
  1597. data/lib/fog/rackspace/requests/load_balancers/delete_nodes.rb +16 -0
  1598. data/lib/fog/rackspace/requests/load_balancers/delete_virtual_ip.rb +15 -0
  1599. data/lib/fog/rackspace/requests/load_balancers/get_connection_logging.rb +15 -0
  1600. data/lib/fog/rackspace/requests/load_balancers/get_connection_throttling.rb +15 -0
  1601. data/lib/fog/rackspace/requests/load_balancers/get_content_caching.rb +15 -0
  1602. data/lib/fog/rackspace/requests/load_balancers/get_error_page.rb +15 -0
  1603. data/lib/fog/rackspace/requests/load_balancers/get_load_balancer.rb +44 -0
  1604. data/lib/fog/rackspace/requests/load_balancers/get_load_balancer_usage.rb +21 -0
  1605. data/lib/fog/rackspace/requests/load_balancers/get_monitor.rb +15 -0
  1606. data/lib/fog/rackspace/requests/load_balancers/get_node.rb +15 -0
  1607. data/lib/fog/rackspace/requests/load_balancers/get_session_persistence.rb +15 -0
  1608. data/lib/fog/rackspace/requests/load_balancers/get_ssl_termination.rb +15 -0
  1609. data/lib/fog/rackspace/requests/load_balancers/get_stats.rb +30 -0
  1610. data/lib/fog/rackspace/requests/load_balancers/get_usage.rb +20 -0
  1611. data/lib/fog/rackspace/requests/load_balancers/list_access_rules.rb +15 -0
  1612. data/lib/fog/rackspace/requests/load_balancers/list_algorithms.rb +15 -0
  1613. data/lib/fog/rackspace/requests/load_balancers/list_load_balancers.rb +21 -0
  1614. data/lib/fog/rackspace/requests/load_balancers/list_nodes.rb +15 -0
  1615. data/lib/fog/rackspace/requests/load_balancers/list_protocols.rb +15 -0
  1616. data/lib/fog/rackspace/requests/load_balancers/list_virtual_ips.rb +15 -0
  1617. data/lib/fog/rackspace/requests/load_balancers/remove_connection_throttling.rb +15 -0
  1618. data/lib/fog/rackspace/requests/load_balancers/remove_error_page.rb +15 -0
  1619. data/lib/fog/rackspace/requests/load_balancers/remove_monitor.rb +15 -0
  1620. data/lib/fog/rackspace/requests/load_balancers/remove_session_persistence.rb +15 -0
  1621. data/lib/fog/rackspace/requests/load_balancers/remove_ssl_termination.rb +15 -0
  1622. data/lib/fog/rackspace/requests/load_balancers/set_connection_logging.rb +21 -0
  1623. data/lib/fog/rackspace/requests/load_balancers/set_connection_throttling.rb +22 -0
  1624. data/lib/fog/rackspace/requests/load_balancers/set_content_caching.rb +21 -0
  1625. data/lib/fog/rackspace/requests/load_balancers/set_error_page.rb +21 -0
  1626. data/lib/fog/rackspace/requests/load_balancers/set_monitor.rb +31 -0
  1627. data/lib/fog/rackspace/requests/load_balancers/set_session_persistence.rb +21 -0
  1628. data/lib/fog/rackspace/requests/load_balancers/set_ssl_termination.rb +31 -0
  1629. data/lib/fog/rackspace/requests/load_balancers/update_load_balancer.rb +26 -0
  1630. data/lib/fog/rackspace/requests/load_balancers/update_node.rb +29 -0
  1631. data/lib/fog/rackspace/requests/monitoring/create_agent_token.rb +47 -0
  1632. data/lib/fog/rackspace/requests/monitoring/create_alarm.rb +47 -0
  1633. data/lib/fog/rackspace/requests/monitoring/create_check.rb +47 -0
  1634. data/lib/fog/rackspace/requests/monitoring/create_entity.rb +47 -0
  1635. data/lib/fog/rackspace/requests/monitoring/create_notification.rb +17 -0
  1636. data/lib/fog/rackspace/requests/monitoring/delete_agent_token.rb +45 -0
  1637. data/lib/fog/rackspace/requests/monitoring/delete_alarm.rb +41 -0
  1638. data/lib/fog/rackspace/requests/monitoring/delete_check.rb +40 -0
  1639. data/lib/fog/rackspace/requests/monitoring/delete_entity.rb +40 -0
  1640. data/lib/fog/rackspace/requests/monitoring/delete_notification.rb +15 -0
  1641. data/lib/fog/rackspace/requests/monitoring/evaluate_alarm_example.rb +18 -0
  1642. data/lib/fog/rackspace/requests/monitoring/get_agent.rb +44 -0
  1643. data/lib/fog/rackspace/requests/monitoring/get_agent_token.rb +47 -0
  1644. data/lib/fog/rackspace/requests/monitoring/get_alarm.rb +51 -0
  1645. data/lib/fog/rackspace/requests/monitoring/get_alarm_example.rb +15 -0
  1646. data/lib/fog/rackspace/requests/monitoring/get_check.rb +56 -0
  1647. data/lib/fog/rackspace/requests/monitoring/get_cpus_info.rb +61 -0
  1648. data/lib/fog/rackspace/requests/monitoring/get_disks_info.rb +54 -0
  1649. data/lib/fog/rackspace/requests/monitoring/get_entity.rb +55 -0
  1650. data/lib/fog/rackspace/requests/monitoring/get_filesystems_info.rb +62 -0
  1651. data/lib/fog/rackspace/requests/monitoring/get_logged_in_user_info.rb +56 -0
  1652. data/lib/fog/rackspace/requests/monitoring/get_memory_info.rb +57 -0
  1653. data/lib/fog/rackspace/requests/monitoring/get_monitoring_zone.rb +15 -0
  1654. data/lib/fog/rackspace/requests/monitoring/get_network_interfaces_info.rb +89 -0
  1655. data/lib/fog/rackspace/requests/monitoring/get_notification.rb +46 -0
  1656. data/lib/fog/rackspace/requests/monitoring/get_processes_info.rb +70 -0
  1657. data/lib/fog/rackspace/requests/monitoring/get_system_info.rb +51 -0
  1658. data/lib/fog/rackspace/requests/monitoring/list_agent_tokens.rb +55 -0
  1659. data/lib/fog/rackspace/requests/monitoring/list_agents.rb +61 -0
  1660. data/lib/fog/rackspace/requests/monitoring/list_alarm_examples.rb +15 -0
  1661. data/lib/fog/rackspace/requests/monitoring/list_alarms.rb +64 -0
  1662. data/lib/fog/rackspace/requests/monitoring/list_check_types.rb +86 -0
  1663. data/lib/fog/rackspace/requests/monitoring/list_checks.rb +70 -0
  1664. data/lib/fog/rackspace/requests/monitoring/list_data_points.rb +51 -0
  1665. data/lib/fog/rackspace/requests/monitoring/list_entities.rb +70 -0
  1666. data/lib/fog/rackspace/requests/monitoring/list_metrics.rb +80 -0
  1667. data/lib/fog/rackspace/requests/monitoring/list_monitoring_zones.rb +15 -0
  1668. data/lib/fog/rackspace/requests/monitoring/list_notification_plans.rb +70 -0
  1669. data/lib/fog/rackspace/requests/monitoring/list_notifications.rb +63 -0
  1670. data/lib/fog/rackspace/requests/monitoring/list_overview.rb +111 -0
  1671. data/lib/fog/rackspace/requests/monitoring/update_alarm.rb +45 -0
  1672. data/lib/fog/rackspace/requests/monitoring/update_check.rb +45 -0
  1673. data/lib/fog/rackspace/requests/monitoring/update_entity.rb +45 -0
  1674. data/lib/fog/rackspace/requests/monitoring/update_notification.rb +16 -0
  1675. data/lib/fog/rackspace/requests/networking/create_network.rb +36 -0
  1676. data/lib/fog/rackspace/requests/networking/create_virtual_interface.rb +30 -0
  1677. data/lib/fog/rackspace/requests/networking/delete_network.rb +21 -0
  1678. data/lib/fog/rackspace/requests/networking/delete_virtual_interface.rb +23 -0
  1679. data/lib/fog/rackspace/requests/networking/get_network.rb +21 -0
  1680. data/lib/fog/rackspace/requests/networking/list_networks.rb +18 -0
  1681. data/lib/fog/rackspace/requests/networking/list_virtual_interfaces.rb +22 -0
  1682. data/lib/fog/rackspace/requests/networking_v2/create_network.rb +18 -0
  1683. data/lib/fog/rackspace/requests/networking_v2/create_port.rb +18 -0
  1684. data/lib/fog/rackspace/requests/networking_v2/create_security_group.rb +12 -0
  1685. data/lib/fog/rackspace/requests/networking_v2/create_security_group_rule.rb +12 -0
  1686. data/lib/fog/rackspace/requests/networking_v2/create_subnet.rb +18 -0
  1687. data/lib/fog/rackspace/requests/networking_v2/delete_network.rb +11 -0
  1688. data/lib/fog/rackspace/requests/networking_v2/delete_port.rb +11 -0
  1689. data/lib/fog/rackspace/requests/networking_v2/delete_security_group.rb +5 -0
  1690. data/lib/fog/rackspace/requests/networking_v2/delete_security_group_rule.rb +5 -0
  1691. data/lib/fog/rackspace/requests/networking_v2/delete_subnet.rb +11 -0
  1692. data/lib/fog/rackspace/requests/networking_v2/list_networks.rb +11 -0
  1693. data/lib/fog/rackspace/requests/networking_v2/list_ports.rb +11 -0
  1694. data/lib/fog/rackspace/requests/networking_v2/list_security_group_rules.rb +5 -0
  1695. data/lib/fog/rackspace/requests/networking_v2/list_security_groups.rb +5 -0
  1696. data/lib/fog/rackspace/requests/networking_v2/list_subnets.rb +11 -0
  1697. data/lib/fog/rackspace/requests/networking_v2/show_network.rb +11 -0
  1698. data/lib/fog/rackspace/requests/networking_v2/show_port.rb +11 -0
  1699. data/lib/fog/rackspace/requests/networking_v2/show_security_group.rb +5 -0
  1700. data/lib/fog/rackspace/requests/networking_v2/show_security_group_rule.rb +5 -0
  1701. data/lib/fog/rackspace/requests/networking_v2/show_subnet.rb +11 -0
  1702. data/lib/fog/rackspace/requests/networking_v2/update_network.rb +18 -0
  1703. data/lib/fog/rackspace/requests/networking_v2/update_port.rb +18 -0
  1704. data/lib/fog/rackspace/requests/networking_v2/update_security_group.rb +12 -0
  1705. data/lib/fog/rackspace/requests/networking_v2/update_subnet.rb +23 -0
  1706. data/lib/fog/rackspace/requests/orchestration/abandon_stack.rb +15 -0
  1707. data/lib/fog/rackspace/requests/orchestration/build_info.rb +15 -0
  1708. data/lib/fog/rackspace/requests/orchestration/create_stack.rb +16 -0
  1709. data/lib/fog/rackspace/requests/orchestration/delete_stack.rb +15 -0
  1710. data/lib/fog/rackspace/requests/orchestration/get_stack_template.rb +20 -0
  1711. data/lib/fog/rackspace/requests/orchestration/list_resource_events.rb +19 -0
  1712. data/lib/fog/rackspace/requests/orchestration/list_resource_types.rb +22 -0
  1713. data/lib/fog/rackspace/requests/orchestration/list_resources.rb +19 -0
  1714. data/lib/fog/rackspace/requests/orchestration/list_stack_data.rb +22 -0
  1715. data/lib/fog/rackspace/requests/orchestration/list_stack_events.rb +19 -0
  1716. data/lib/fog/rackspace/requests/orchestration/preview_stack.rb +16 -0
  1717. data/lib/fog/rackspace/requests/orchestration/show_event_details.rb +22 -0
  1718. data/lib/fog/rackspace/requests/orchestration/show_resource_data.rb +22 -0
  1719. data/lib/fog/rackspace/requests/orchestration/show_resource_metadata.rb +22 -0
  1720. data/lib/fog/rackspace/requests/orchestration/show_resource_schema.rb +15 -0
  1721. data/lib/fog/rackspace/requests/orchestration/show_resource_template.rb +20 -0
  1722. data/lib/fog/rackspace/requests/orchestration/show_stack_details.rb +22 -0
  1723. data/lib/fog/rackspace/requests/orchestration/update_stack.rb +16 -0
  1724. data/lib/fog/rackspace/requests/orchestration/validate_template.rb +16 -0
  1725. data/lib/fog/rackspace/requests/queues/create_claim.rb +72 -0
  1726. data/lib/fog/rackspace/requests/queues/create_message.rb +56 -0
  1727. data/lib/fog/rackspace/requests/queues/create_queue.rb +39 -0
  1728. data/lib/fog/rackspace/requests/queues/delete_claim.rb +42 -0
  1729. data/lib/fog/rackspace/requests/queues/delete_message.rb +62 -0
  1730. data/lib/fog/rackspace/requests/queues/delete_queue.rb +33 -0
  1731. data/lib/fog/rackspace/requests/queues/get_claim.rb +37 -0
  1732. data/lib/fog/rackspace/requests/queues/get_message.rb +41 -0
  1733. data/lib/fog/rackspace/requests/queues/get_queue.rb +36 -0
  1734. data/lib/fog/rackspace/requests/queues/get_queue_stats.rb +57 -0
  1735. data/lib/fog/rackspace/requests/queues/list_messages.rb +73 -0
  1736. data/lib/fog/rackspace/requests/queues/list_queues.rb +62 -0
  1737. data/lib/fog/rackspace/requests/queues/update_claim.rb +39 -0
  1738. data/lib/fog/rackspace/requests/storage/copy_object.rb +29 -0
  1739. data/lib/fog/rackspace/requests/storage/delete_container.rb +36 -0
  1740. data/lib/fog/rackspace/requests/storage/delete_multiple_objects.rb +128 -0
  1741. data/lib/fog/rackspace/requests/storage/delete_object.rb +36 -0
  1742. data/lib/fog/rackspace/requests/storage/delete_static_large_object.rb +78 -0
  1743. data/lib/fog/rackspace/requests/storage/extract_archive.rb +37 -0
  1744. data/lib/fog/rackspace/requests/storage/get_container.rb +69 -0
  1745. data/lib/fog/rackspace/requests/storage/get_containers.rb +51 -0
  1746. data/lib/fog/rackspace/requests/storage/get_object.rb +54 -0
  1747. data/lib/fog/rackspace/requests/storage/get_object_http_url.rb +35 -0
  1748. data/lib/fog/rackspace/requests/storage/get_object_https_url.rb +71 -0
  1749. data/lib/fog/rackspace/requests/storage/head_container.rb +41 -0
  1750. data/lib/fog/rackspace/requests/storage/head_containers.rb +44 -0
  1751. data/lib/fog/rackspace/requests/storage/head_object.rb +48 -0
  1752. data/lib/fog/rackspace/requests/storage/post_set_meta_temp_url_key.rb +46 -0
  1753. data/lib/fog/rackspace/requests/storage/put_container.rb +38 -0
  1754. data/lib/fog/rackspace/requests/storage/put_dynamic_obj_manifest.rb +63 -0
  1755. data/lib/fog/rackspace/requests/storage/put_object.rb +77 -0
  1756. data/lib/fog/rackspace/requests/storage/put_object_manifest.rb +22 -0
  1757. data/lib/fog/rackspace/requests/storage/put_static_obj_manifest.rb +102 -0
  1758. data/lib/fog/rackspace/service.rb +142 -0
  1759. data/lib/fog/rackspace/storage.rb +465 -0
  1760. data/lib/fog/rage4/dns.rb +0 -1
  1761. data/lib/fog/vcloud_director/README.md +0 -3
  1762. data/lib/fog/vcloud_director/compute.rb +2 -29
  1763. data/lib/fog/vcloud_director/generators/compute/edge_gateway_service_configuration.rb +1 -1
  1764. data/lib/fog/vcloud_director/models/compute/catalog_item.rb +0 -7
  1765. data/lib/fog/vcloud_director/models/compute/disks.rb +0 -6
  1766. data/lib/fog/vcloud_director/models/compute/networks.rb +2 -7
  1767. data/lib/fog/vcloud_director/models/compute/vdc.rb +0 -10
  1768. data/lib/fog/vcloud_director/models/compute/vm.rb +1 -28
  1769. data/lib/fog/vcloud_director/parsers/compute/vm.rb +10 -19
  1770. data/lib/fog/vcloud_director/parsers/compute/vm_customization.rb +0 -1
  1771. data/lib/fog/vcloud_director/parsers/compute/vms.rb +38 -15
  1772. data/lib/fog/vcloud_director/requests/compute/delete_vapp.rb +0 -30
  1773. data/lib/fog/vcloud_director/requests/compute/get_catalog.rb +3 -24
  1774. data/lib/fog/vcloud_director/requests/compute/get_catalog_item.rb +0 -23
  1775. data/lib/fog/vcloud_director/requests/compute/get_execute_query.rb +10 -13
  1776. data/lib/fog/vcloud_director/requests/compute/get_metadata.rb +0 -11
  1777. data/lib/fog/vcloud_director/requests/compute/get_vapp.rb +0 -1
  1778. data/lib/fog/vcloud_director/requests/compute/get_vdc.rb +1 -1
  1779. data/lib/fog/vcloud_director/requests/compute/get_vm.rb +0 -46
  1780. data/lib/fog/vcloud_director/requests/compute/get_vm_disks.rb +0 -20
  1781. data/lib/fog/vcloud_director/requests/compute/get_vm_network.rb +0 -25
  1782. data/lib/fog/vcloud_director/requests/compute/get_vms.rb +0 -13
  1783. data/lib/fog/vcloud_director/requests/compute/instantiate_vapp_template.rb +37 -100
  1784. data/lib/fog/vcloud_director/requests/compute/post_power_on_vapp.rb +0 -35
  1785. data/lib/fog/vcloud_director/requests/compute/post_update_vapp_metadata.rb +0 -34
  1786. data/lib/fog/vcloud_director/requests/compute/put_guest_customization_section_vapp.rb +1 -2
  1787. data/lib/fog/vcloud_director/requests/compute/put_network_connection_system_section_vapp.rb +0 -31
  1788. data/lib/fog/vcloud_director/requests/compute/put_product_sections.rb +1 -4
  1789. data/lib/fog/version.rb +1 -1
  1790. data/lib/fog/vsphere.rb +1 -0
  1791. data/lib/fog/vsphere/compute.rb +466 -0
  1792. data/lib/fog/vsphere/core.rb +39 -0
  1793. data/lib/fog/vsphere/models/compute/cluster.rb +28 -0
  1794. data/lib/fog/vsphere/models/compute/clusters.rb +23 -0
  1795. data/lib/fog/vsphere/models/compute/customfield.rb +16 -0
  1796. data/lib/fog/vsphere/models/compute/customfields.rb +24 -0
  1797. data/lib/fog/vsphere/models/compute/customvalue.rb +14 -0
  1798. data/lib/fog/vsphere/models/compute/customvalues.rb +34 -0
  1799. data/lib/fog/vsphere/models/compute/datacenter.rb +44 -0
  1800. data/lib/fog/vsphere/models/compute/datacenters.rb +20 -0
  1801. data/lib/fog/vsphere/models/compute/datastore.rb +21 -0
  1802. data/lib/fog/vsphere/models/compute/datastores.rb +22 -0
  1803. data/lib/fog/vsphere/models/compute/folder.rb +24 -0
  1804. data/lib/fog/vsphere/models/compute/folders.rb +24 -0
  1805. data/lib/fog/vsphere/models/compute/interface.rb +91 -0
  1806. data/lib/fog/vsphere/models/compute/interfaces.rb +67 -0
  1807. data/lib/fog/vsphere/models/compute/interfacetype.rb +22 -0
  1808. data/lib/fog/vsphere/models/compute/interfacetypes.rb +35 -0
  1809. data/lib/fog/vsphere/models/compute/network.rb +17 -0
  1810. data/lib/fog/vsphere/models/compute/networks.rb +23 -0
  1811. data/lib/fog/vsphere/models/compute/resource_pool.rb +19 -0
  1812. data/lib/fog/vsphere/models/compute/resource_pools.rb +23 -0
  1813. data/lib/fog/vsphere/models/compute/scsicontroller.rb +16 -0
  1814. data/lib/fog/vsphere/models/compute/server.rb +296 -0
  1815. data/lib/fog/vsphere/models/compute/servers.rb +37 -0
  1816. data/lib/fog/vsphere/models/compute/servertype.rb +36 -0
  1817. data/lib/fog/vsphere/models/compute/servertypes.rb +24 -0
  1818. data/lib/fog/vsphere/models/compute/template.rb +11 -0
  1819. data/lib/fog/vsphere/models/compute/templates.rb +20 -0
  1820. data/lib/fog/vsphere/models/compute/volume.rb +99 -0
  1821. data/lib/fog/vsphere/models/compute/volumes.rb +54 -0
  1822. data/lib/fog/vsphere/requests/compute/cloudinit_to_customspec.rb +65 -0
  1823. data/lib/fog/vsphere/requests/compute/create_folder.rb +22 -0
  1824. data/lib/fog/vsphere/requests/compute/create_vm.rb +164 -0
  1825. data/lib/fog/vsphere/requests/compute/current_time.rb +18 -0
  1826. data/lib/fog/vsphere/requests/compute/get_cluster.rb +25 -0
  1827. data/lib/fog/vsphere/requests/compute/get_compute_resource.rb +41 -0
  1828. data/lib/fog/vsphere/requests/compute/get_datacenter.rb +31 -0
  1829. data/lib/fog/vsphere/requests/compute/get_datastore.rb +30 -0
  1830. data/lib/fog/vsphere/requests/compute/get_folder.rb +74 -0
  1831. data/lib/fog/vsphere/requests/compute/get_interface_type.rb +15 -0
  1832. data/lib/fog/vsphere/requests/compute/get_network.rb +59 -0
  1833. data/lib/fog/vsphere/requests/compute/get_resource_pool.rb +26 -0
  1834. data/lib/fog/vsphere/requests/compute/get_server_type.rb +32 -0
  1835. data/lib/fog/vsphere/requests/compute/get_template.rb +16 -0
  1836. data/lib/fog/vsphere/requests/compute/get_virtual_machine.rb +57 -0
  1837. data/lib/fog/vsphere/requests/compute/get_vm_first_scsi_controller.rb +26 -0
  1838. data/lib/fog/vsphere/requests/compute/list_clusters.rb +72 -0
  1839. data/lib/fog/vsphere/requests/compute/list_compute_resources.rb +92 -0
  1840. data/lib/fog/vsphere/requests/compute/list_customfields.rb +21 -0
  1841. data/lib/fog/vsphere/requests/compute/list_datacenters.rb +53 -0
  1842. data/lib/fog/vsphere/requests/compute/list_datastores.rb +40 -0
  1843. data/lib/fog/vsphere/requests/compute/list_folders.rb +44 -0
  1844. data/lib/fog/vsphere/requests/compute/list_interface_types.rb +25 -0
  1845. data/lib/fog/vsphere/requests/compute/list_networks.rb +37 -0
  1846. data/lib/fog/vsphere/requests/compute/list_resource_pools.rb +38 -0
  1847. data/lib/fog/vsphere/requests/compute/list_server_types.rb +54 -0
  1848. data/lib/fog/vsphere/requests/compute/list_templates.rb +48 -0
  1849. data/lib/fog/vsphere/requests/compute/list_virtual_machines.rb +80 -0
  1850. data/lib/fog/vsphere/requests/compute/list_vm_customvalues.rb +20 -0
  1851. data/lib/fog/vsphere/requests/compute/list_vm_interfaces.rb +63 -0
  1852. data/lib/fog/vsphere/requests/compute/list_vm_volumes.rb +52 -0
  1853. data/lib/fog/vsphere/requests/compute/modify_vm_interface.rb +59 -0
  1854. data/lib/fog/vsphere/requests/compute/modify_vm_volume.rb +25 -0
  1855. data/lib/fog/vsphere/requests/compute/set_vm_customvalue.rb +17 -0
  1856. data/lib/fog/vsphere/requests/compute/vm_clone.rb +730 -0
  1857. data/lib/fog/vsphere/requests/compute/vm_config_vnc.rb +45 -0
  1858. data/lib/fog/vsphere/requests/compute/vm_destroy.rb +23 -0
  1859. data/lib/fog/vsphere/requests/compute/vm_execute.rb +47 -0
  1860. data/lib/fog/vsphere/requests/compute/vm_migrate.rb +33 -0
  1861. data/lib/fog/vsphere/requests/compute/vm_power_off.rb +39 -0
  1862. data/lib/fog/vsphere/requests/compute/vm_power_on.rb +26 -0
  1863. data/lib/fog/vsphere/requests/compute/vm_reboot.rb +31 -0
  1864. data/lib/fog/vsphere/requests/compute/vm_reconfig_cpus.rb +23 -0
  1865. data/lib/fog/vsphere/requests/compute/vm_reconfig_hardware.rb +24 -0
  1866. data/lib/fog/vsphere/requests/compute/vm_reconfig_memory.rb +23 -0
  1867. data/lib/tasks/changelog_task.rb +5 -11
  1868. data/lib/tasks/github_release_task.rb +1 -1
  1869. data/spec/fog/bin/digitalocean_spec.rb +9 -0
  1870. data/spec/fog/bin/dnsimple_spec.rb +2 -2
  1871. data/spec/fog/bin/hp_spec.rb +10 -0
  1872. data/spec/fog/bin/internetarchive_spec.rb +10 -0
  1873. data/spec/fog/bin/ninefold_spec.rb +10 -0
  1874. data/spec/fog/bin/ovirt_spec.rb +10 -0
  1875. data/spec/fog/bin_spec.rb +9 -3
  1876. data/spec/fog/openstack/identity_v3/authv3_a.yml +81 -0
  1877. data/spec/fog/openstack/identity_v3/authv3_b.yml +81 -0
  1878. data/spec/fog/openstack/identity_v3/authv3_c.yml +187 -0
  1879. data/spec/fog/openstack/identity_v3/authv3_project.yml +105 -0
  1880. data/spec/fog/openstack/identity_v3/authv3_token.yml +452 -0
  1881. data/spec/fog/openstack/identity_v3/authv3_unscoped.yml +477 -0
  1882. data/spec/fog/openstack/identity_v3/authv3_unscoped_reauth.yml +371 -0
  1883. data/spec/fog/openstack/identity_v3/common_setup.yml +476 -0
  1884. data/spec/fog/openstack/identity_v3/idv3_credential.yml +117 -0
  1885. data/spec/fog/openstack/identity_v3/idv3_credential_crud.yml +561 -0
  1886. data/spec/fog/openstack/identity_v3/idv3_domain.yml +201 -0
  1887. data/spec/fog/openstack/identity_v3/idv3_domain_crud.yml +469 -0
  1888. data/spec/fog/openstack/identity_v3/idv3_domain_group_roles_mutation.yml +804 -0
  1889. data/spec/fog/openstack/identity_v3/idv3_domain_roles_mutation.yml +478 -0
  1890. data/spec/fog/openstack/identity_v3/idv3_endpoint.yml +621 -0
  1891. data/spec/fog/openstack/identity_v3/idv3_endpoints_crud.yml +952 -0
  1892. data/spec/fog/openstack/identity_v3/idv3_group_crud_mutation.yml +1055 -0
  1893. data/spec/fog/openstack/identity_v3/idv3_other_region.yml +187 -0
  1894. data/spec/fog/openstack/identity_v3/idv3_policy.yml +155 -0
  1895. data/spec/fog/openstack/identity_v3/idv3_policy_crud.yml +388 -0
  1896. data/spec/fog/openstack/identity_v3/idv3_project.yml +241 -0
  1897. data/spec/fog/openstack/identity_v3/idv3_project_crud.yml +455 -0
  1898. data/spec/fog/openstack/identity_v3/idv3_project_group_user_roles_mutation.yml +1237 -0
  1899. data/spec/fog/openstack/identity_v3/idv3_project_hier_crud_list.yml +1394 -0
  1900. data/spec/fog/openstack/identity_v3/idv3_role.yml +233 -0
  1901. data/spec/fog/openstack/identity_v3/idv3_role_crud.yml +408 -0
  1902. data/spec/fog/openstack/identity_v3/idv3_service.yml +285 -0
  1903. data/spec/fog/openstack/identity_v3/idv3_services_crud.yml +506 -0
  1904. data/spec/fog/openstack/identity_v3/idv3_token.yml +334 -0
  1905. data/spec/fog/openstack/identity_v3/idv3_user_crud.yml +655 -0
  1906. data/spec/fog/openstack/identity_v3/idv3_users.yml +323 -0
  1907. data/spec/fog/openstack/identity_v3_spec.rb +1016 -0
  1908. data/spec/fog/openstack/network/common_setup.yml +131 -0
  1909. data/spec/fog/openstack/network/subnets_crud.yml +140 -0
  1910. data/spec/fog/openstack/network_spec.rb +43 -0
  1911. data/spec/fog/openstack/shared_context.rb +98 -0
  1912. data/spec/fog/openstack/volume/common_setup.yml +76 -0
  1913. data/spec/fog/openstack/volume/volume_crud.yml +561 -0
  1914. data/spec/fog/openstack/volume/volume_extend.yml +762 -0
  1915. data/spec/fog/openstack/volume/volume_transfer_and_accept.yml +1078 -0
  1916. data/spec/fog/openstack/volume/volume_transfer_and_delete.yml +695 -0
  1917. data/spec/fog/openstack/volume/volume_type_read.yml +120 -0
  1918. data/spec/fog/openstack/volume_spec.rb +335 -0
  1919. data/tests/cloudsigma/models/volume_tests.rb +3 -3
  1920. data/tests/cloudsigma/requests/server_tests.rb +10 -10
  1921. data/tests/cloudsigma/requests/volumes_tests.rb +11 -12
  1922. data/tests/compute/helper.rb +22 -0
  1923. data/tests/digitalocean/helper.rb +56 -0
  1924. data/tests/digitalocean/models/compute/flavor_tests.rb +29 -0
  1925. data/tests/digitalocean/models/compute/image_tests.rb +30 -0
  1926. data/tests/digitalocean/models/compute/region_tests.rb +29 -0
  1927. data/tests/digitalocean/models/compute/server_tests.rb +93 -0
  1928. data/tests/digitalocean/models/compute/servers_tests.rb +39 -0
  1929. data/tests/digitalocean/models/compute/ssh_key_tests.rb +43 -0
  1930. data/tests/digitalocean/models/compute/ssh_keys_tests.rb +32 -0
  1931. data/tests/digitalocean/requests/compute/create_server_tests.rb +32 -0
  1932. data/tests/digitalocean/requests/compute/create_ssh_key_tests.rb +22 -0
  1933. data/tests/digitalocean/requests/compute/destroy_server_tests.rb +14 -0
  1934. data/tests/digitalocean/requests/compute/destroy_ssh_key_tests.rb +23 -0
  1935. data/tests/digitalocean/requests/compute/get_server_details_tests.rb +13 -0
  1936. data/tests/digitalocean/requests/compute/get_ssh_key_tests.rb +25 -0
  1937. data/tests/digitalocean/requests/compute/list_flavors_tests.rb +23 -0
  1938. data/tests/digitalocean/requests/compute/list_images_tests.rb +24 -0
  1939. data/tests/digitalocean/requests/compute/list_regions_tests.rb +23 -0
  1940. data/tests/digitalocean/requests/compute/list_servers_tests.rb +27 -0
  1941. data/tests/digitalocean/requests/compute/list_ssh_keys_tests.rb +24 -0
  1942. data/tests/digitalocean/requests/compute/power_cycle_server_tests.rb +20 -0
  1943. data/tests/digitalocean/requests/compute/power_state_tests.rb +25 -0
  1944. data/tests/digitalocean/requests/compute/reboot_server_tests.rb +14 -0
  1945. data/tests/dnsimple/requests/dns/dns_tests.rb +122 -0
  1946. data/tests/helper.rb +0 -1
  1947. data/tests/helpers/mock_helper.rb +13 -1
  1948. data/tests/hp/block_storage_tests.rb +47 -0
  1949. data/tests/hp/cdn_tests.rb +23 -0
  1950. data/tests/hp/compute_tests.rb +22 -0
  1951. data/tests/hp/models/block_storage/bootable_volume_tests.rb +23 -0
  1952. data/tests/hp/models/block_storage/snapshot_tests.rb +23 -0
  1953. data/tests/hp/models/block_storage/volume_tests.rb +21 -0
  1954. data/tests/hp/models/block_storage_v2/snapshot_tests.rb +22 -0
  1955. data/tests/hp/models/block_storage_v2/snapshots_tests.rb +10 -0
  1956. data/tests/hp/models/block_storage_v2/volume_backup_tests.rb +22 -0
  1957. data/tests/hp/models/block_storage_v2/volume_backups_tests.rb +9 -0
  1958. data/tests/hp/models/block_storage_v2/volume_tests.rb +22 -0
  1959. data/tests/hp/models/block_storage_v2/volumes_tests.rb +5 -0
  1960. data/tests/hp/models/compute/address_tests.rb +18 -0
  1961. data/tests/hp/models/compute/addresses_tests.rb +5 -0
  1962. data/tests/hp/models/compute/key_pair_tests.rb +26 -0
  1963. data/tests/hp/models/compute/key_pairs_tests.rb +5 -0
  1964. data/tests/hp/models/compute/metadata_image_tests.rb +60 -0
  1965. data/tests/hp/models/compute/metadata_server_tests.rb +54 -0
  1966. data/tests/hp/models/compute/security_group_tests.rb +38 -0
  1967. data/tests/hp/models/compute/security_groups_tests.rb +5 -0
  1968. data/tests/hp/models/compute_v2/address_tests.rb +23 -0
  1969. data/tests/hp/models/compute_v2/addresses_tests.rb +7 -0
  1970. data/tests/hp/models/compute_v2/availability_zone_tests.rb +11 -0
  1971. data/tests/hp/models/compute_v2/availability_zones_tests.rb +13 -0
  1972. data/tests/hp/models/compute_v2/key_pair_tests.rb +28 -0
  1973. data/tests/hp/models/compute_v2/key_pairs_tests.rb +7 -0
  1974. data/tests/hp/models/compute_v2/metadata_image_tests.rb +60 -0
  1975. data/tests/hp/models/compute_v2/metadata_server_tests.rb +56 -0
  1976. data/tests/hp/models/compute_v2/server_tests.rb +45 -0
  1977. data/tests/hp/models/compute_v2/servers_tests.rb +9 -0
  1978. data/tests/hp/models/compute_v2/volume_attachment_tests.rb +40 -0
  1979. data/tests/hp/models/compute_v2/volume_attachments_tests.rb +17 -0
  1980. data/tests/hp/models/dns/domain_tests.rb +25 -0
  1981. data/tests/hp/models/dns/domains_tests.rb +14 -0
  1982. data/tests/hp/models/dns/record_tests.rb +29 -0
  1983. data/tests/hp/models/dns/records_tests.rb +9 -0
  1984. data/tests/hp/models/lb/algorithms_tests.rb +15 -0
  1985. data/tests/hp/models/lb/load_balancer_node_tests.rb +9 -0
  1986. data/tests/hp/models/lb/load_balancer_nodes_tests.rb +27 -0
  1987. data/tests/hp/models/lb/load_balancer_tests.rb +6 -0
  1988. data/tests/hp/models/lb/load_balancer_virtual_ips_tests.rb +22 -0
  1989. data/tests/hp/models/lb/load_balancers_tests.rb +22 -0
  1990. data/tests/hp/models/lb/protocols_tests.rb +15 -0
  1991. data/tests/hp/models/network/floating_ip_tests.rb +37 -0
  1992. data/tests/hp/models/network/floating_ips_tests.rb +8 -0
  1993. data/tests/hp/models/network/network_tests.rb +25 -0
  1994. data/tests/hp/models/network/networks_tests.rb +15 -0
  1995. data/tests/hp/models/network/port_tests.rb +30 -0
  1996. data/tests/hp/models/network/ports_tests.rb +21 -0
  1997. data/tests/hp/models/network/router_tests.rb +55 -0
  1998. data/tests/hp/models/network/routers_tests.rb +19 -0
  1999. data/tests/hp/models/network/security_group_rule_tests.rb +25 -0
  2000. data/tests/hp/models/network/security_group_rules_tests.rb +23 -0
  2001. data/tests/hp/models/network/security_group_tests.rb +20 -0
  2002. data/tests/hp/models/network/security_groups_tests.rb +20 -0
  2003. data/tests/hp/models/network/subnet_tests.rb +30 -0
  2004. data/tests/hp/models/network/subnets_tests.rb +22 -0
  2005. data/tests/hp/models/storage/directories_tests.rb +23 -0
  2006. data/tests/hp/models/storage/directory_tests.rb +131 -0
  2007. data/tests/hp/models/storage/file_tests.rb +44 -0
  2008. data/tests/hp/models/storage/files_tests.rb +38 -0
  2009. data/tests/hp/requests/block_storage/bootable_volume_tests.rb +78 -0
  2010. data/tests/hp/requests/block_storage/snapshot_tests.rb +56 -0
  2011. data/tests/hp/requests/block_storage/volume_tests.rb +94 -0
  2012. data/tests/hp/requests/block_storage_v2/snapshot_tests.rb +69 -0
  2013. data/tests/hp/requests/block_storage_v2/volume_backup_tests.rb +117 -0
  2014. data/tests/hp/requests/block_storage_v2/volume_tests.rb +106 -0
  2015. data/tests/hp/requests/cdn/container_tests.rb +56 -0
  2016. data/tests/hp/requests/compute/address_tests.rb +72 -0
  2017. data/tests/hp/requests/compute/flavor_tests.rb +45 -0
  2018. data/tests/hp/requests/compute/image_tests.rb +79 -0
  2019. data/tests/hp/requests/compute/key_pair_tests.rb +65 -0
  2020. data/tests/hp/requests/compute/metadata_tests.rb +70 -0
  2021. data/tests/hp/requests/compute/persistent_server_tests.rb +66 -0
  2022. data/tests/hp/requests/compute/security_group_rule_tests.rb +54 -0
  2023. data/tests/hp/requests/compute/security_group_tests.rb +63 -0
  2024. data/tests/hp/requests/compute/server_address_tests.rb +45 -0
  2025. data/tests/hp/requests/compute/server_tests.rb +126 -0
  2026. data/tests/hp/requests/compute/server_volume_tests.rb +75 -0
  2027. data/tests/hp/requests/compute_v2/address_tests.rb +80 -0
  2028. data/tests/hp/requests/compute_v2/availability_zone_tests.rb +19 -0
  2029. data/tests/hp/requests/compute_v2/flavor_tests.rb +45 -0
  2030. data/tests/hp/requests/compute_v2/image_tests.rb +86 -0
  2031. data/tests/hp/requests/compute_v2/key_pair_tests.rb +66 -0
  2032. data/tests/hp/requests/compute_v2/metadata_tests.rb +101 -0
  2033. data/tests/hp/requests/compute_v2/persistent_server_tests.rb +67 -0
  2034. data/tests/hp/requests/compute_v2/server_address_tests.rb +46 -0
  2035. data/tests/hp/requests/compute_v2/server_security_group_tests.rb +42 -0
  2036. data/tests/hp/requests/compute_v2/server_tests.rb +113 -0
  2037. data/tests/hp/requests/compute_v2/server_volume_tests.rb +84 -0
  2038. data/tests/hp/requests/dns/domain_tests.rb +72 -0
  2039. data/tests/hp/requests/dns/records_tests.rb +64 -0
  2040. data/tests/hp/requests/lb/algorithms_tests.rb +14 -0
  2041. data/tests/hp/requests/lb/limits_tests.rb +16 -0
  2042. data/tests/hp/requests/lb/load_balancer_nodes_tests.rb +46 -0
  2043. data/tests/hp/requests/lb/load_balancer_tests.rb +56 -0
  2044. data/tests/hp/requests/lb/protocols_tests.rb +14 -0
  2045. data/tests/hp/requests/lb/versions_tests.rb +16 -0
  2046. data/tests/hp/requests/lb/virtual_ips_tests.rb +34 -0
  2047. data/tests/hp/requests/network/floating_ip_tests.rb +70 -0
  2048. data/tests/hp/requests/network/network_tests.rb +57 -0
  2049. data/tests/hp/requests/network/port_tests.rb +71 -0
  2050. data/tests/hp/requests/network/router_tests.rb +108 -0
  2051. data/tests/hp/requests/network/security_group_rule_tests.rb +58 -0
  2052. data/tests/hp/requests/network/security_group_tests.rb +48 -0
  2053. data/tests/hp/requests/network/subnet_tests.rb +71 -0
  2054. data/tests/hp/requests/storage/container_tests.rb +86 -0
  2055. data/tests/hp/requests/storage/object_tests.rb +121 -0
  2056. data/tests/hp/storage_tests.rb +28 -0
  2057. data/tests/hp/user_agent_tests.rb +13 -0
  2058. data/tests/internet_archive/models/storage/directory_tests.rb +42 -0
  2059. data/tests/internet_archive/models/storage/file_tests.rb +61 -0
  2060. data/tests/internet_archive/models/storage/files_tests.rb +58 -0
  2061. data/tests/internet_archive/models/storage/url_tests.rb +28 -0
  2062. data/tests/internet_archive/requests/storage/acl_utils_tests.rb +209 -0
  2063. data/tests/internet_archive/requests/storage/bucket_tests.rb +324 -0
  2064. data/tests/internet_archive/requests/storage/cors_utils_tests.rb +108 -0
  2065. data/tests/internet_archive/requests/storage/multipart_upload_tests.rb +132 -0
  2066. data/tests/internet_archive/requests/storage/object_tests.rb +166 -0
  2067. data/tests/internet_archive/signaturev4_tests.rb +41 -0
  2068. data/tests/internet_archive/signed_params_tests.rb +5 -0
  2069. data/tests/joyent/models/analytics/field_tests.rb +10 -0
  2070. data/tests/joyent/models/analytics/fields_tests.rb +13 -0
  2071. data/tests/joyent/models/analytics/instrumentation_tests.rb +13 -0
  2072. data/tests/joyent/models/analytics/instrumentations_tests.rb +3 -0
  2073. data/tests/joyent/models/analytics/joyent_module_tests.rb +10 -0
  2074. data/tests/joyent/models/analytics/joyent_modules_tests.rb +13 -0
  2075. data/tests/joyent/models/analytics/metric_tests.rb +10 -0
  2076. data/tests/joyent/models/analytics/metrics_tests.rb +20 -0
  2077. data/tests/joyent/models/analytics/transformation_tests.rb +10 -0
  2078. data/tests/joyent/models/analytics/transformations_tests.rb +13 -0
  2079. data/tests/joyent/models/analytics/type_tests.rb +10 -0
  2080. data/tests/joyent/models/analytics/types_tests.rb +13 -0
  2081. data/tests/joyent/requests/analytics/instrumentation_tests.rb +44 -0
  2082. data/tests/joyent/requests/compute/datasets_tests.rb +58 -0
  2083. data/tests/joyent/requests/compute/keys_tests.rb +47 -0
  2084. data/tests/joyent/requests/compute/machines_tests.rb +66 -0
  2085. data/tests/joyent/requests/compute/networks_tests.rb +39 -0
  2086. data/tests/joyent/requests/compute/packages_tests.rb +68 -0
  2087. data/tests/linode/requests/compute/datacenter_tests.rb +1 -2
  2088. data/tests/linode/requests/compute/kernel_tests.rb +10 -2
  2089. data/tests/linode/requests/compute/linodeplans_tests.rb +7 -10
  2090. data/tests/ninefold/models/storage/file_update_tests.rb +19 -0
  2091. data/tests/ninefold/models/storage/nested_directories_tests.rb +23 -0
  2092. data/tests/ninefold/requests/compute/address_tests.rb +42 -0
  2093. data/tests/ninefold/requests/compute/async_job_tests.rb +33 -0
  2094. data/tests/ninefold/requests/compute/helper.rb +369 -0
  2095. data/tests/ninefold/requests/compute/list_tests.rb +56 -0
  2096. data/tests/ninefold/requests/compute/load_balancer_tests.rb +66 -0
  2097. data/tests/ninefold/requests/compute/nat_tests.rb +91 -0
  2098. data/tests/ninefold/requests/compute/network_tests.rb +21 -0
  2099. data/tests/ninefold/requests/compute/template_tests.rb +21 -0
  2100. data/tests/ninefold/requests/compute/virtual_machine_tests.rb +68 -0
  2101. data/tests/opennebula/models/compute/flavor_tests.rb +3 -3
  2102. data/tests/opennebula/models/compute/network_tests.rb +2 -1
  2103. data/tests/opennebula/requests/compute/vm_allocate_tests.rb +3 -20
  2104. data/tests/openstack/authenticate_tests.rb +193 -0
  2105. data/tests/openstack/models/compute/images_tests.rb +13 -0
  2106. data/tests/openstack/models/compute/security_group_tests.rb +54 -0
  2107. data/tests/openstack/models/compute/server_tests.rb +220 -0
  2108. data/tests/openstack/models/identity/ec2_credential_tests.rb +41 -0
  2109. data/tests/openstack/models/identity/ec2_credentials_tests.rb +58 -0
  2110. data/tests/openstack/models/identity/role_tests.rb +26 -0
  2111. data/tests/openstack/models/identity/roles_tests.rb +20 -0
  2112. data/tests/openstack/models/identity/tenant_tests.rb +30 -0
  2113. data/tests/openstack/models/identity/tenants_tests.rb +26 -0
  2114. data/tests/openstack/models/identity/user_tests.rb +46 -0
  2115. data/tests/openstack/models/identity/users_tests.rb +42 -0
  2116. data/tests/openstack/models/image/image_tests.rb +36 -0
  2117. data/tests/openstack/models/image/images_tests.rb +19 -0
  2118. data/tests/openstack/models/network/floating_ip_tests.rb +22 -0
  2119. data/tests/openstack/models/network/floating_ips_tests.rb +19 -0
  2120. data/tests/openstack/models/network/lb_health_monitor_tests.rb +52 -0
  2121. data/tests/openstack/models/network/lb_health_monitors_tests.rb +21 -0
  2122. data/tests/openstack/models/network/lb_member_tests.rb +28 -0
  2123. data/tests/openstack/models/network/lb_members_tests.rb +21 -0
  2124. data/tests/openstack/models/network/lb_pool_tests.rb +53 -0
  2125. data/tests/openstack/models/network/lb_pools_tests.rb +20 -0
  2126. data/tests/openstack/models/network/lb_vip_tests.rb +39 -0
  2127. data/tests/openstack/models/network/lb_vips_tests.rb +21 -0
  2128. data/tests/openstack/models/network/network_tests.rb +61 -0
  2129. data/tests/openstack/models/network/networks_tests.rb +21 -0
  2130. data/tests/openstack/models/network/port_tests.rb +28 -0
  2131. data/tests/openstack/models/network/ports_tests.rb +25 -0
  2132. data/tests/openstack/models/network/router_tests.rb +39 -0
  2133. data/tests/openstack/models/network/routers_tests.rb +21 -0
  2134. data/tests/openstack/models/network/security_group_rule_tests.rb +27 -0
  2135. data/tests/openstack/models/network/security_group_rules_tests.rb +25 -0
  2136. data/tests/openstack/models/network/security_group_tests.rb +17 -0
  2137. data/tests/openstack/models/network/security_groups_tests.rb +16 -0
  2138. data/tests/openstack/models/network/subnet_tests.rb +30 -0
  2139. data/tests/openstack/models/network/subnets_tests.rb +27 -0
  2140. data/tests/openstack/models/planning/.gitkeep +0 -0
  2141. data/tests/openstack/models/planning/plan_tests.rb +51 -0
  2142. data/tests/openstack/models/planning/plans_tests.rb +18 -0
  2143. data/tests/openstack/models/planning/role_tests.rb +14 -0
  2144. data/tests/openstack/models/storage/file_tests.rb +222 -0
  2145. data/tests/openstack/requests/baremetal/chassis_tests.rb +48 -0
  2146. data/tests/openstack/requests/baremetal/driver_tests.rb +40 -0
  2147. data/tests/openstack/requests/baremetal/node_tests.rb +83 -0
  2148. data/tests/openstack/requests/baremetal/port_tests.rb +56 -0
  2149. data/tests/openstack/requests/compute/address_tests.rb +58 -0
  2150. data/tests/openstack/requests/compute/aggregate_tests.rb +59 -0
  2151. data/tests/openstack/requests/compute/availability_zone_tests.rb +18 -0
  2152. data/tests/openstack/requests/compute/flavor_tests.rb +95 -0
  2153. data/tests/openstack/requests/compute/helper.rb +41 -0
  2154. data/tests/openstack/requests/compute/image_tests.rb +58 -0
  2155. data/tests/openstack/requests/compute/keypair_tests.rb +30 -0
  2156. data/tests/openstack/requests/compute/limit_tests.rb +59 -0
  2157. data/tests/openstack/requests/compute/quota_tests.rb +60 -0
  2158. data/tests/openstack/requests/compute/security_group_tests.rb +61 -0
  2159. data/tests/openstack/requests/compute/server_tests.rb +289 -0
  2160. data/tests/openstack/requests/compute/service_tests.rb +33 -0
  2161. data/tests/openstack/requests/compute/tenant_tests.rb +19 -0
  2162. data/tests/openstack/requests/compute/volume_tests.rb +38 -0
  2163. data/tests/openstack/requests/identity/ec2_credentials_tests.rb +44 -0
  2164. data/tests/openstack/requests/identity/helper.rb +13 -0
  2165. data/tests/openstack/requests/identity/role_tests.rb +45 -0
  2166. data/tests/openstack/requests/identity/tenant_tests.rb +56 -0
  2167. data/tests/openstack/requests/identity/user_tests.rb +41 -0
  2168. data/tests/openstack/requests/image/image_tests.rb +134 -0
  2169. data/tests/openstack/requests/metering/meter_tests.rb +52 -0
  2170. data/tests/openstack/requests/metering/resource_tests.rb +19 -0
  2171. data/tests/openstack/requests/network/lb_health_monitor_tests.rb +93 -0
  2172. data/tests/openstack/requests/network/lb_member_tests.rb +60 -0
  2173. data/tests/openstack/requests/network/lb_pool_tests.rb +80 -0
  2174. data/tests/openstack/requests/network/lb_vip_tests.rb +71 -0
  2175. data/tests/openstack/requests/network/network_tests.rb +107 -0
  2176. data/tests/openstack/requests/network/port_tests.rb +66 -0
  2177. data/tests/openstack/requests/network/quota_tests.rb +65 -0
  2178. data/tests/openstack/requests/network/router_tests.rb +73 -0
  2179. data/tests/openstack/requests/network/security_group_rule_tests.rb +58 -0
  2180. data/tests/openstack/requests/network/security_group_tests.rb +43 -0
  2181. data/tests/openstack/requests/network/subnet_tests.rb +66 -0
  2182. data/tests/openstack/requests/orchestration/stack_tests.rb +64 -0
  2183. data/tests/openstack/requests/planning/.gitkeep +0 -0
  2184. data/tests/openstack/requests/planning/plan_tests.rb +65 -0
  2185. data/tests/openstack/requests/planning/role_tests.rb +16 -0
  2186. data/tests/openstack/requests/storage/container_tests.rb +64 -0
  2187. data/tests/openstack/requests/storage/large_object_tests.rb +372 -0
  2188. data/tests/openstack/requests/storage/object_tests.rb +208 -0
  2189. data/tests/openstack/requests/volume/availability_zone_tests.rb +13 -0
  2190. data/tests/openstack/requests/volume/quota_tests.rb +50 -0
  2191. data/tests/openstack/requests/volume/volume_type_tests.rb +32 -0
  2192. data/tests/openstack/storage_tests.rb +18 -0
  2193. data/tests/openstack/version_tests.rb +55 -0
  2194. data/tests/openstack/volume_tests.rb +14 -0
  2195. data/tests/ovirt/compute_tests.rb +25 -0
  2196. data/tests/ovirt/models/compute/cluster_tests.rb +31 -0
  2197. data/tests/ovirt/models/compute/clusters_tests.rb +9 -0
  2198. data/tests/ovirt/models/compute/interface_tests.rb +27 -0
  2199. data/tests/ovirt/models/compute/interfaces_tests.rb +9 -0
  2200. data/tests/ovirt/models/compute/server_tests.rb +51 -0
  2201. data/tests/ovirt/models/compute/servers_tests.rb +14 -0
  2202. data/tests/ovirt/models/compute/template_tests.rb +28 -0
  2203. data/tests/ovirt/models/compute/templates_tests.rb +9 -0
  2204. data/tests/ovirt/requests/compute/create_vm_tests.rb +26 -0
  2205. data/tests/ovirt/requests/compute/destroy_vm_tests.rb +18 -0
  2206. data/tests/ovirt/requests/compute/list_datacenters_tests.rb +13 -0
  2207. data/tests/ovirt/requests/compute/list_quotas_tests.rb +12 -0
  2208. data/tests/ovirt/requests/compute/list_storage_domains_tests.rb +13 -0
  2209. data/tests/ovirt/requests/compute/update_vm_tests.rb +18 -0
  2210. data/tests/ovirt/requests/compute/update_volume_tests.rb +20 -0
  2211. data/tests/rackspace/auto_scale_tests.rb +83 -0
  2212. data/tests/rackspace/block_storage_tests.rb +119 -0
  2213. data/tests/rackspace/cdn_tests.rb +186 -0
  2214. data/tests/rackspace/compute_tests.rb +100 -0
  2215. data/tests/rackspace/compute_v2_tests.rb +118 -0
  2216. data/tests/rackspace/databases_tests.rb +140 -0
  2217. data/tests/rackspace/dns_tests.rb +110 -0
  2218. data/tests/rackspace/helper.rb +106 -0
  2219. data/tests/rackspace/identity_tests.rb +26 -0
  2220. data/tests/rackspace/load_balancer_tests.rb +135 -0
  2221. data/tests/rackspace/models/auto_scale/group_builder_tests.rb +145 -0
  2222. data/tests/rackspace/models/auto_scale/group_tests.rb +35 -0
  2223. data/tests/rackspace/models/auto_scale/groups_tests.rb +17 -0
  2224. data/tests/rackspace/models/auto_scale/policies_tests.rb +24 -0
  2225. data/tests/rackspace/models/auto_scale/policy_tests.rb +35 -0
  2226. data/tests/rackspace/models/auto_scale/webhook_tests.rb +42 -0
  2227. data/tests/rackspace/models/auto_scale/webhooks_tests.rb +28 -0
  2228. data/tests/rackspace/models/block_storage/snapshot_tests.rb +25 -0
  2229. data/tests/rackspace/models/block_storage/snapshots_tests.rb +18 -0
  2230. data/tests/rackspace/models/block_storage/volume_tests.rb +31 -0
  2231. data/tests/rackspace/models/block_storage/volume_types_tests.rb +18 -0
  2232. data/tests/rackspace/models/block_storage/volumes_tests.rb +9 -0
  2233. data/tests/rackspace/models/compute_v2/flavors_tests.rb +17 -0
  2234. data/tests/rackspace/models/compute_v2/image_tests.rb +74 -0
  2235. data/tests/rackspace/models/compute_v2/images_tests.rb +20 -0
  2236. data/tests/rackspace/models/compute_v2/keypairs_tests.rb +47 -0
  2237. data/tests/rackspace/models/compute_v2/metadata_tests.rb +44 -0
  2238. data/tests/rackspace/models/compute_v2/network_tests.rb +10 -0
  2239. data/tests/rackspace/models/compute_v2/networks_tests.rb +10 -0
  2240. data/tests/rackspace/models/compute_v2/server_tests.rb +274 -0
  2241. data/tests/rackspace/models/compute_v2/servers_tests.rb +22 -0
  2242. data/tests/rackspace/models/compute_v2/virtual_interface_tests.rb +33 -0
  2243. data/tests/rackspace/models/compute_v2/virtual_interfaces_tests.rb +24 -0
  2244. data/tests/rackspace/models/databases/database_tests.rb +29 -0
  2245. data/tests/rackspace/models/databases/databases_tests.rb +17 -0
  2246. data/tests/rackspace/models/databases/flavors_tests.rb +20 -0
  2247. data/tests/rackspace/models/databases/instance_tests.rb +43 -0
  2248. data/tests/rackspace/models/databases/instances_tests.rb +14 -0
  2249. data/tests/rackspace/models/databases/user_tests.rb +21 -0
  2250. data/tests/rackspace/models/databases/users_tests.rb +21 -0
  2251. data/tests/rackspace/models/dns/zone_tests.rb +14 -0
  2252. data/tests/rackspace/models/dns/zones_tests.rb +36 -0
  2253. data/tests/rackspace/models/identity/credentials_tests.rb +25 -0
  2254. data/tests/rackspace/models/identity/roles_tests.rb +16 -0
  2255. data/tests/rackspace/models/identity/service_catalog_tests.rb +154 -0
  2256. data/tests/rackspace/models/identity/tenants_tests.rb +21 -0
  2257. data/tests/rackspace/models/identity/user_tests.rb +17 -0
  2258. data/tests/rackspace/models/identity/users_tests.rb +17 -0
  2259. data/tests/rackspace/models/load_balancers/access_list_tests.rb +12 -0
  2260. data/tests/rackspace/models/load_balancers/access_lists_tests.rb +12 -0
  2261. data/tests/rackspace/models/load_balancers/load_balancer_tests.rb +229 -0
  2262. data/tests/rackspace/models/load_balancers/load_balancers_tests.rb +19 -0
  2263. data/tests/rackspace/models/load_balancers/node_tests.rb +19 -0
  2264. data/tests/rackspace/models/load_balancers/nodes_tests.rb +12 -0
  2265. data/tests/rackspace/models/load_balancers/virtual_ip_tests.rb +16 -0
  2266. data/tests/rackspace/models/load_balancers/virtual_ips_tests.rb +12 -0
  2267. data/tests/rackspace/models/monitoring/agent_token_tests.rb +9 -0
  2268. data/tests/rackspace/models/monitoring/agent_tokens_tests.rb +9 -0
  2269. data/tests/rackspace/models/monitoring/alarm_example_tests.rb +18 -0
  2270. data/tests/rackspace/models/monitoring/alarm_examples_tests.rb +19 -0
  2271. data/tests/rackspace/models/monitoring/alarm_tests.rb +59 -0
  2272. data/tests/rackspace/models/monitoring/alarms_tests.rb +25 -0
  2273. data/tests/rackspace/models/monitoring/check_tests.rb +49 -0
  2274. data/tests/rackspace/models/monitoring/check_types_tests.rb +14 -0
  2275. data/tests/rackspace/models/monitoring/checks_tests.rb +16 -0
  2276. data/tests/rackspace/models/monitoring/data_points_tests.rb +19 -0
  2277. data/tests/rackspace/models/monitoring/entities_tests.rb +14 -0
  2278. data/tests/rackspace/models/monitoring/entity_tests.rb +26 -0
  2279. data/tests/rackspace/models/monitoring/metric_tests.rb +19 -0
  2280. data/tests/rackspace/models/monitoring/metrics_tests.rb +17 -0
  2281. data/tests/rackspace/models/monitoring/notification_tests.rb +19 -0
  2282. data/tests/rackspace/models/monitoring/notifications_tests.rb +10 -0
  2283. data/tests/rackspace/models/networking/network_tests.rb +10 -0
  2284. data/tests/rackspace/models/networking/networks_tests.rb +10 -0
  2285. data/tests/rackspace/models/networking/virtual_interface_tests.rb +33 -0
  2286. data/tests/rackspace/models/networking/virtual_interfaces_tests.rb +24 -0
  2287. data/tests/rackspace/models/queues/claim_tests.rb +41 -0
  2288. data/tests/rackspace/models/queues/claims_tests.rb +53 -0
  2289. data/tests/rackspace/models/queues/message_tests.rb +49 -0
  2290. data/tests/rackspace/models/queues/messages_tests.rb +16 -0
  2291. data/tests/rackspace/models/queues/queue_tests.rb +37 -0
  2292. data/tests/rackspace/models/queues/queues_tests.rb +8 -0
  2293. data/tests/rackspace/models/storage/account_tests.rb +26 -0
  2294. data/tests/rackspace/models/storage/directories_tests.rb +26 -0
  2295. data/tests/rackspace/models/storage/directory_tests.rb +138 -0
  2296. data/tests/rackspace/models/storage/file_tests.rb +400 -0
  2297. data/tests/rackspace/models/storage/files_tests.rb +39 -0
  2298. data/tests/rackspace/models/storage/metadata_tests.rb +208 -0
  2299. data/tests/rackspace/monitoring_tests.rb +76 -0
  2300. data/tests/rackspace/networking_tests.rb +118 -0
  2301. data/tests/rackspace/queues_tests.rb +105 -0
  2302. data/tests/rackspace/rackspace_tests.rb +56 -0
  2303. data/tests/rackspace/requests/auto_scale/config_tests.rb +97 -0
  2304. data/tests/rackspace/requests/auto_scale/group_tests.rb +50 -0
  2305. data/tests/rackspace/requests/auto_scale/helper.rb +224 -0
  2306. data/tests/rackspace/requests/auto_scale/policy_tests.rb +71 -0
  2307. data/tests/rackspace/requests/auto_scale/webhook_tests.rb +58 -0
  2308. data/tests/rackspace/requests/block_storage/snapshot_tests.rb +80 -0
  2309. data/tests/rackspace/requests/block_storage/volume_tests.rb +75 -0
  2310. data/tests/rackspace/requests/block_storage/volume_type_tests.rb +21 -0
  2311. data/tests/rackspace/requests/cdn/cdn_tests.rb +75 -0
  2312. data/tests/rackspace/requests/compute/address_tests.rb +42 -0
  2313. data/tests/rackspace/requests/compute/flavor_tests.rb +39 -0
  2314. data/tests/rackspace/requests/compute/helper.rb +10 -0
  2315. data/tests/rackspace/requests/compute/image_tests.rb +70 -0
  2316. data/tests/rackspace/requests/compute/resize_tests.rb +35 -0
  2317. data/tests/rackspace/requests/compute/server_tests.rb +94 -0
  2318. data/tests/rackspace/requests/compute_v2/address_tests.rb +45 -0
  2319. data/tests/rackspace/requests/compute_v2/attachment_tests.rb +66 -0
  2320. data/tests/rackspace/requests/compute_v2/flavor_tests.rb +47 -0
  2321. data/tests/rackspace/requests/compute_v2/image_tests.rb +77 -0
  2322. data/tests/rackspace/requests/compute_v2/keypair_tests.rb +55 -0
  2323. data/tests/rackspace/requests/compute_v2/metadata_tests.rb +104 -0
  2324. data/tests/rackspace/requests/compute_v2/network_tests.rb +49 -0
  2325. data/tests/rackspace/requests/compute_v2/server_tests.rb +168 -0
  2326. data/tests/rackspace/requests/compute_v2/virtual_interface_tests.rb +49 -0
  2327. data/tests/rackspace/requests/databases/database_tests.rb +39 -0
  2328. data/tests/rackspace/requests/databases/flavor_tests.rb +16 -0
  2329. data/tests/rackspace/requests/databases/helper.rb +79 -0
  2330. data/tests/rackspace/requests/databases/instance_tests.rb +77 -0
  2331. data/tests/rackspace/requests/databases/user_tests.rb +37 -0
  2332. data/tests/rackspace/requests/dns/dns_tests.rb +125 -0
  2333. data/tests/rackspace/requests/dns/helper.rb +124 -0
  2334. data/tests/rackspace/requests/dns/records_tests.rb +83 -0
  2335. data/tests/rackspace/requests/identity/tenants_tests.rb +21 -0
  2336. data/tests/rackspace/requests/identity/token_tests.rb +70 -0
  2337. data/tests/rackspace/requests/identity/user_tests.rb +106 -0
  2338. data/tests/rackspace/requests/load_balancers/access_list_tests.rb +56 -0
  2339. data/tests/rackspace/requests/load_balancers/algorithm_tests.rb +19 -0
  2340. data/tests/rackspace/requests/load_balancers/connection_logging_tests.rb +25 -0
  2341. data/tests/rackspace/requests/load_balancers/connection_throttling_tests.rb +37 -0
  2342. data/tests/rackspace/requests/load_balancers/content_caching_tests.rb +25 -0
  2343. data/tests/rackspace/requests/load_balancers/error_page_tests.rb +31 -0
  2344. data/tests/rackspace/requests/load_balancers/get_stats_tests.rb +13 -0
  2345. data/tests/rackspace/requests/load_balancers/helper.rb +229 -0
  2346. data/tests/rackspace/requests/load_balancers/load_balancer_tests.rb +86 -0
  2347. data/tests/rackspace/requests/load_balancers/load_balancer_usage_tests.rb +19 -0
  2348. data/tests/rackspace/requests/load_balancers/monitor_tests.rb +46 -0
  2349. data/tests/rackspace/requests/load_balancers/node_tests.rb +86 -0
  2350. data/tests/rackspace/requests/load_balancers/protocol_tests.rb +21 -0
  2351. data/tests/rackspace/requests/load_balancers/session_persistence_tests.rb +33 -0
  2352. data/tests/rackspace/requests/load_balancers/ssl_termination_tests.rb +38 -0
  2353. data/tests/rackspace/requests/load_balancers/usage_tests.rb +19 -0
  2354. data/tests/rackspace/requests/load_balancers/virtual_ip_tests.rb +40 -0
  2355. data/tests/rackspace/requests/monitoring/agent_tests.rb +74 -0
  2356. data/tests/rackspace/requests/monitoring/alarm_example_tests.rb +30 -0
  2357. data/tests/rackspace/requests/monitoring/alarm_tests.rb +55 -0
  2358. data/tests/rackspace/requests/monitoring/check_tests.rb +39 -0
  2359. data/tests/rackspace/requests/monitoring/entity_tests.rb +36 -0
  2360. data/tests/rackspace/requests/monitoring/helper.rb +139 -0
  2361. data/tests/rackspace/requests/monitoring/list_tests.rb +83 -0
  2362. data/tests/rackspace/requests/monitoring/notification_tests.rb +46 -0
  2363. data/tests/rackspace/requests/networking/network_tests.rb +49 -0
  2364. data/tests/rackspace/requests/networking/virtual_interface_tests.rb +49 -0
  2365. data/tests/rackspace/requests/queues/claim_tests.rb +60 -0
  2366. data/tests/rackspace/requests/queues/helper.rb +50 -0
  2367. data/tests/rackspace/requests/queues/messages_tests.rb +54 -0
  2368. data/tests/rackspace/requests/queues/queues_tests.rb +38 -0
  2369. data/tests/rackspace/requests/storage/account_tests.rb +15 -0
  2370. data/tests/rackspace/requests/storage/container_tests.rb +67 -0
  2371. data/tests/rackspace/requests/storage/large_object_tests.rb +355 -0
  2372. data/tests/rackspace/requests/storage/object_tests.rb +230 -0
  2373. data/tests/rackspace/service_tests.rb +82 -0
  2374. data/tests/rackspace/storage_tests.rb +128 -0
  2375. data/tests/rackspace/url_encoding_tests.rb +5 -0
  2376. data/tests/rage4/requests/dns/dns_tests.rb +0 -12
  2377. data/tests/storage/helper.rb +9 -0
  2378. data/tests/vcloud_director/models/compute/catalog_items_tests.rb +0 -1
  2379. data/tests/vcloud_director/models/compute/vms_tests.rb +0 -2
  2380. data/tests/vcloud_director/requests/compute/edge_gateway_tests.rb +1 -1
  2381. data/tests/vsphere/compute_tests.rb +53 -0
  2382. data/tests/vsphere/models/compute/server_tests.rb +44 -0
  2383. data/tests/vsphere/models/compute/servers_tests.rb +15 -0
  2384. data/tests/vsphere/requests/compute/current_time_tests.rb +12 -0
  2385. data/tests/vsphere/requests/compute/get_network_tests.rb +48 -0
  2386. data/tests/vsphere/requests/compute/list_clusters_tests.rb +11 -0
  2387. data/tests/vsphere/requests/compute/list_virtual_machines_tests.rb +38 -0
  2388. data/tests/vsphere/requests/compute/set_vm_customvalue_tests.rb +20 -0
  2389. data/tests/vsphere/requests/compute/vm_clone_tests.rb +50 -0
  2390. data/tests/vsphere/requests/compute/vm_config_vnc_tests.rb +19 -0
  2391. data/tests/vsphere/requests/compute/vm_destroy_tests.rb +17 -0
  2392. data/tests/vsphere/requests/compute/vm_migrate_tests.rb +16 -0
  2393. data/tests/vsphere/requests/compute/vm_power_off_tests.rb +26 -0
  2394. data/tests/vsphere/requests/compute/vm_power_on_tests.rb +17 -0
  2395. data/tests/vsphere/requests/compute/vm_reboot_tests.rb +26 -0
  2396. data/tests/vsphere/requests/compute/vm_reconfig_cpus_tests.rb +19 -0
  2397. data/tests/vsphere/requests/compute/vm_reconfig_hardware_tests.rb +19 -0
  2398. data/tests/vsphere/requests/compute/vm_reconfig_memory_tests.rb +19 -0
  2399. metadata +2851 -247
  2400. data/gemfiles/Gemfile-1.9 +0 -16
  2401. data/gemfiles/Gemfile-2.0 +0 -11
  2402. data/gemfiles/Gemfile-edge-1.9 +0 -20
  2403. data/gemfiles/Gemfile-edge-2.0 +0 -16
  2404. data/lib/fog/cloudsigma/models/snapshot.rb +0 -77
  2405. data/lib/fog/cloudsigma/models/snapshots.rb +0 -26
  2406. data/lib/fog/cloudsigma/requests/clone_snapshot.rb +0 -31
  2407. data/lib/fog/cloudsigma/requests/create_snapshot.rb +0 -27
  2408. data/lib/fog/cloudsigma/requests/delete_snapshot.rb +0 -17
  2409. data/lib/fog/cloudsigma/requests/get_snapshot.rb +0 -17
  2410. data/lib/fog/cloudsigma/requests/list_snapshots.rb +0 -17
  2411. data/lib/fog/cloudsigma/requests/update_snapshot.rb +0 -17
  2412. data/lib/fog/linode/models/compute/node_balancer_flavor.rb +0 -13
  2413. data/lib/fog/linode/models/compute/node_balancer_flavors.rb +0 -27
  2414. data/lib/fog/linode/requests/compute/avail_nodebalancers.rb +0 -42
  2415. data/lib/fog/opennebula/requests/compute/vm_suspend.rb +0 -31
  2416. data/lib/fog/rage4/requests/dns/bulk_update_records.rb +0 -38
  2417. data/lib/fog/vcloud_director/generators/compute/compose_common.rb +0 -122
  2418. data/lib/fog/vcloud_director/generators/compute/compose_vapp.rb +0 -25
  2419. data/lib/fog/vcloud_director/generators/compute/create_snapshot.rb +0 -25
  2420. data/lib/fog/vcloud_director/generators/compute/instantiate_vapp_template_params.rb +0 -30
  2421. data/lib/fog/vcloud_director/generators/compute/recompose_vapp.rb +0 -34
  2422. data/lib/fog/vcloud_director/models/compute/template_vm.rb +0 -52
  2423. data/lib/fog/vcloud_director/models/compute/template_vms.rb +0 -41
  2424. data/lib/fog/vcloud_director/models/compute/vapp_template.rb +0 -26
  2425. data/lib/fog/vcloud_director/models/compute/vapp_templates.rb +0 -40
  2426. data/lib/fog/vcloud_director/parsers/compute/vm_parser_helper.rb +0 -62
  2427. data/lib/fog/vcloud_director/requests/compute/get_template_vm.rb +0 -74
  2428. data/lib/fog/vcloud_director/requests/compute/get_template_vms.rb +0 -41
  2429. data/lib/fog/vcloud_director/requests/compute/post_compose_vapp.rb +0 -45
  2430. data/lib/fog/vcloud_director/requests/compute/post_create_snapshot.rb +0 -21
  2431. data/lib/fog/vcloud_director/requests/compute/post_recompose_vapp.rb +0 -21
  2432. data/lib/fog/vcloud_director/requests/compute/post_reconfigure_vm.rb +0 -118
  2433. data/spec/vcloud_director/generators/compute/instantiate_vapp_template_params_spec.rb +0 -68
  2434. data/spec/vcloud_director/requests/compute/instantiate_vapp_template_spec.rb +0 -78
  2435. data/spec/vcloud_director/spec_helper.rb +0 -11
  2436. data/tests/cloudsigma/models/snapshot_tests.rb +0 -23
  2437. data/tests/cloudsigma/models/snapshots_tests.rb +0 -15
  2438. data/tests/cloudsigma/requests/snapshots_tests.rb +0 -83
  2439. data/tests/linode/requests/compute/nodebalancers_tests.rb +0 -20
  2440. data/tests/opennebula/requests/compute/vm_suspend_resume_tests.rb +0 -52
  2441. data/tests/vcloud_director/fixtures/vapp.xml +0 -532
  2442. data/tests/vcloud_director/fixtures/vm.xml +0 -213
  2443. data/tests/vcloud_director/generators/compute/compose_vapp_tests.rb +0 -108
  2444. data/tests/vcloud_director/models/compute/vapp_template_tests.rb +0 -29
@@ -0,0 +1,48 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def list_templates(options = { })
6
+ options[:folder] ||= options['folder']
7
+ if options[:folder] then
8
+ list_all_templates_in_folder(options[:folder], options[:datacenter])
9
+ else
10
+ list_all_templates(options)
11
+ end
12
+ end
13
+
14
+ private
15
+
16
+ def list_all_templates_in_folder(path, datacenter_name)
17
+ folder = get_raw_vmfolder(path, datacenter_name)
18
+
19
+ vms = folder.children.grep(RbVmomi::VIM::VirtualMachine)
20
+ # remove all virtual machines that are not template
21
+ vms.delete_if { |v| v.config.nil? or not v.config.template }
22
+
23
+ vms.map(&method(:convert_vm_mob_ref_to_attr_hash))
24
+ end
25
+
26
+ def list_all_templates(options = {})
27
+ datacenters = find_datacenters(options[:datacenter])
28
+
29
+ vms = datacenters.map do |dc|
30
+ @connection.serviceContent.viewManager.CreateContainerView({
31
+ :container => dc.vmFolder,
32
+ :type => ["VirtualMachine"],
33
+ :recursive => true
34
+ }).view
35
+ end.flatten
36
+ # remove all virtual machines that are not templates
37
+ vms.delete_if { |v| v.config.nil? or not v.config.template }
38
+
39
+ vms.map(&method(:convert_vm_mob_ref_to_attr_hash))
40
+ end
41
+ end
42
+ class Mock
43
+ def list_templates(filters = { })
44
+ end
45
+ end
46
+ end
47
+ end
48
+ end
@@ -0,0 +1,80 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def list_virtual_machines(options = { })
6
+ # Listing all VM's can be quite slow and expensive. Try and optimize
7
+ # based on the available options we have. These conditions are in
8
+ # ascending order of time to complete for large deployments.
9
+
10
+ options[:folder] ||= options['folder']
11
+ if options['instance_uuid'] then
12
+ [get_virtual_machine(options['instance_uuid'])]
13
+ elsif options[:folder] && options[:datacenter] then
14
+ list_all_virtual_machines_in_folder(options[:folder], options[:datacenter])
15
+ else
16
+ list_all_virtual_machines(options)
17
+ end
18
+ end
19
+
20
+
21
+ private
22
+
23
+ def list_all_virtual_machines_in_folder(path, datacenter_name)
24
+ folder = get_raw_vmfolder(path, datacenter_name)
25
+
26
+ vms = folder.children.grep(RbVmomi::VIM::VirtualMachine)
27
+ # remove all template based virtual machines
28
+ vms.delete_if { |v| v.config.nil? or v.config.template }
29
+ vms.map(&method(:convert_vm_mob_ref_to_attr_hash))
30
+ end
31
+
32
+ def list_all_virtual_machines(options = { })
33
+ raw_vms = raw_list_all_virtual_machines(options[:datacenter])
34
+ vms = convert_vm_view_to_attr_hash(raw_vms)
35
+
36
+ # remove all template based virtual machines
37
+ vms.delete_if { |v| v['template'] }
38
+ vms
39
+ end
40
+
41
+ def raw_list_all_virtual_machines(datacenter_name = nil)
42
+ ## Moved this to its own function since trying to get a list of all virtual machines
43
+ ## to parse for a find function took way too long. The raw list returned will make it
44
+ ## much faster to interact for some functions.
45
+ datacenters = find_datacenters(datacenter_name)
46
+ datacenters.map do |dc|
47
+ @connection.serviceContent.viewManager.CreateContainerView({
48
+ :container => dc.vmFolder,
49
+ :type => ["VirtualMachine"],
50
+ :recursive => true
51
+ }).view
52
+ end.flatten
53
+ end
54
+ def get_folder_path(folder, root = nil)
55
+ if (not folder.methods.include?('parent')) or (folder == root)
56
+ return
57
+ end
58
+ "#{get_folder_path(folder.parent)}/#{folder.name}"
59
+ end
60
+ end
61
+
62
+ class Mock
63
+ def get_folder_path(folder, root = nil)
64
+ nil
65
+ end
66
+
67
+ def list_virtual_machines(options = { })
68
+ if options['instance_uuid'].nil? and options['mo_ref'].nil?
69
+ self.data[:servers].values
70
+ elsif !options['instance_uuid'].nil?
71
+ server = self.data[:servers][options['instance_uuid']]
72
+ server.nil? ? [] : [server]
73
+ else
74
+ self.data[:servers].values.select{|vm| vm['mo_ref'] == options['mo_ref']}
75
+ end
76
+ end
77
+ end
78
+ end
79
+ end
80
+ end
@@ -0,0 +1,20 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def list_vm_customvalues(vm_id)
6
+ get_vm_ref(vm_id).summary.customValue.map do |customvalue|
7
+ {
8
+ :key => customvalue.key.to_i,
9
+ :value => customvalue.value,
10
+ }
11
+ end
12
+ end
13
+ end
14
+ class Mock
15
+ def list_vm_customfields(vm_id)
16
+ end
17
+ end
18
+ end
19
+ end
20
+ end
@@ -0,0 +1,63 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ # => VirtualE1000(
6
+ #addressType: "assigned",
7
+ #backing: VirtualEthernetCardNetworkBackingInfo(
8
+ # deviceName: "VM Network",
9
+ # dynamicProperty: [],
10
+ # network: Network("network-163"),
11
+ # useAutoDetect: false
12
+ #),
13
+ #connectable: VirtualDeviceConnectInfo(
14
+ # allowGuestControl: true,
15
+ # connected: true,
16
+ # dynamicProperty: [],
17
+ # startConnected: true,
18
+ # status: "ok"
19
+ #),
20
+ #controllerKey: 100,
21
+ #deviceInfo: Description(
22
+ # dynamicProperty: [],
23
+ # label: "Network adapter 1",
24
+ # summary: "VM Network"
25
+ #),
26
+ #dynamicProperty: [],
27
+ #key: 4000,
28
+ #macAddress: "00:50:56:a9:00:28",
29
+ #unitNumber: 7,
30
+ #
31
+ def list_vm_interfaces(vm_id, datacenter = nil)
32
+ get_vm_ref(vm_id, datacenter).config.hardware.device.grep(RbVmomi::VIM::VirtualEthernetCard).map do |nic|
33
+ {
34
+ :name => nic.deviceInfo.label,
35
+ :mac => nic.macAddress,
36
+ :network => nic.backing.respond_to?("network") ? nic.backing.network.name : nic.backing.port.portgroupKey,
37
+ :status => nic.connectable.status,
38
+ :summary => nic.deviceInfo.summary,
39
+ :type => nic.class,
40
+ :key => nic.key,
41
+ }
42
+ end
43
+ end
44
+
45
+ def get_vm_interface(vm_id, options={})
46
+ raise ArgumentError, "instance id is a required parameter" unless vm_id
47
+ if options.is_a? Fog::Compute::Vsphere::Interface
48
+ options
49
+ else
50
+ raise ArgumentError, "Either key or name is a required parameter. options: #{options}" unless options.key? :key or options.key? :mac or options.key? :name
51
+ list_vm_interfaces(vm_id).find do | nic |
52
+ (options.key? :key and nic[:key]==options[:key].to_i) or (options.key? :mac and nic[:mac]==options[:mac]) or (options.key? :name and nic[:name]==options[:name])
53
+ end
54
+ end
55
+ end
56
+ end
57
+ class Mock
58
+ def list_vm_interfaces(vm_id)
59
+ end
60
+ end
61
+ end
62
+ end
63
+ end
@@ -0,0 +1,52 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ # [VirtualDisk(
6
+ # backing: VirtualDiskFlatVer2BackingInfo(
7
+ # contentId: "a172d19487e878e17d6b16ff2505d7eb",
8
+ # datastore: Datastore("datastore-162"),
9
+ # diskMode: "persistent",
10
+ # dynamicProperty: [],
11
+ # fileName: "[Storage1] rhel6-mfojtik/rhel6-mfojtik.vmdk",
12
+ # split: false,
13
+ # thinProvisioned: true,
14
+ # uuid: "6000C29c-a47d-4cd9-5249-c371de775f06",
15
+ # writeThrough: false
16
+ # ),
17
+ # capacityInKB: 8388608,
18
+ # controllerKey: 1000,
19
+ # deviceInfo: Description(
20
+ # dynamicProperty: [],
21
+ # label: "Hard disk 1",
22
+ # summary: "8,388,608 KB"
23
+ # ),
24
+ # dynamicProperty: [],
25
+ # key: 2001,
26
+ # shares: SharesInfo( dynamicProperty: [], level: "normal", shares: 1000 ),
27
+ # unitNumber: 1
28
+ #)]
29
+
30
+ def list_vm_volumes(vm_id)
31
+ get_vm_ref(vm_id).disks.map do |vol|
32
+ {
33
+ :id => vol.backing.uuid,
34
+ :thin => (vol.backing.thinProvisioned rescue(nil)),
35
+ :mode => vol.backing.diskMode,
36
+ :filename => vol.backing.fileName,
37
+ :datastore => (vol.backing.datastore.name rescue(nil)),
38
+ :size => vol.capacityInKB,
39
+ :name => vol.deviceInfo.label,
40
+ :key => vol.key,
41
+ :unit_number => vol.unitNumber
42
+ }
43
+ end
44
+ end
45
+ end
46
+ class Mock
47
+ def list_vm_volumes(vm_id)
48
+ end
49
+ end
50
+ end
51
+ end
52
+ end
@@ -0,0 +1,59 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def add_vm_interface(vmid, options = {})
6
+ raise ArgumentError, "instance id is a required parameter" unless vmid
7
+
8
+ interface = get_interface_from_options(vmid, options.merge(:server_id => vmid))
9
+ vm_reconfig_hardware('instance_uuid' => vmid, 'hardware_spec' => {'deviceChange'=>[create_interface(interface, 0, :add, options)]})
10
+ end
11
+
12
+ def destroy_vm_interface(vmid, options = {})
13
+ raise ArgumentError, "instance id is a required parameter" unless vmid
14
+
15
+ interface = get_interface_from_options(vmid, options.merge(:server_id => vmid))
16
+ vm_reconfig_hardware('instance_uuid' => vmid, 'hardware_spec' => {'deviceChange'=>[create_interface(interface, interface.key, :remove)]})
17
+ end
18
+
19
+ def update_vm_interface(vmid, options = {})
20
+ raise ArgumentError, "instance id is a required parameter" unless vmid
21
+
22
+ interface = get_interface_from_options(vmid, options.merge(:server_id => vmid))
23
+ vm_reconfig_hardware('instance_uuid' => vmid, 'hardware_spec' => {'deviceChange'=>[create_interface(interface, interface.key, :edit)]})
24
+ end
25
+
26
+ private
27
+ def get_interface_from_options(vmid, options)
28
+ if options and options[:interface]
29
+ options[:interface]
30
+
31
+ elsif options[:key] and options[:key]>0
32
+ oldattributes = get_vm_interface(vmid, options)
33
+ Fog::Compute::Vsphere::Interface.new(oldattributes.merge(options))
34
+
35
+ elsif options[:type] and options[:network]
36
+ Fog::Compute::Vsphere::Interface.new options
37
+
38
+ else
39
+ raise ArgumentError, "interface is a required parameter or pass options with type and network"
40
+ end
41
+ end
42
+ end
43
+
44
+ class Mock
45
+ def add_vm_interface(vmid, options = {})
46
+ raise ArgumentError, "instance id is a required parameter" unless vmid
47
+ raise ArgumentError, "interface is a required parameter" unless options and options[:interface]
48
+ true
49
+ end
50
+
51
+ def destroy_vm_interface(vmid, options = {})
52
+ raise ArgumentError, "instance id is a required parameter" unless vmid
53
+ raise ArgumentError, "interface is a required parameter" unless options and options[:interface]
54
+ true
55
+ end
56
+ end
57
+ end
58
+ end
59
+ end
@@ -0,0 +1,25 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def add_vm_volume(volume)
6
+ vm_reconfig_hardware('instance_uuid' => volume.server_id, 'hardware_spec' => {'deviceChange'=>[create_disk(volume, volume.unit_number, :add)]})
7
+ end
8
+
9
+ def destroy_vm_volume(volume)
10
+ vm_reconfig_hardware('instance_uuid' => volume.server_id, 'hardware_spec' => {'deviceChange'=>[create_disk(volume, volume.unit_number, :remove)]})
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def add_vm_volume(volume)
16
+ true
17
+ end
18
+
19
+ def destroy_vm_volume(volume)
20
+ true
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,17 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ class Real
5
+ def set_vm_customvalue(vm_id, key, value)
6
+ vm_ref = get_vm_ref(vm_id)
7
+ vm_ref.setCustomValue(:key => key, :value => value)
8
+ end
9
+ end
10
+ class Mock
11
+ def set_vm_customvalue(vm_id, key, value)
12
+ nil
13
+ end
14
+ end
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,730 @@
1
+ module Fog
2
+ module Compute
3
+ class Vsphere
4
+ module Shared
5
+ private
6
+ def vm_clone_check_options(options)
7
+ default_options = {
8
+ 'force' => false,
9
+ 'linked_clone' => false,
10
+ 'nic_type' => 'VirtualE1000',
11
+ }
12
+ options = default_options.merge(options)
13
+ # Backwards compat for "path" option
14
+ options["template_path"] ||= options["path"]
15
+ options["path"] ||= options["template_path"]
16
+ required_options = %w{ datacenter template_path name }
17
+ required_options.each do |param|
18
+ raise ArgumentError, "#{required_options.join(', ')} are required" unless options.key? param
19
+ end
20
+ raise Fog::Compute::Vsphere::NotFound, "Datacenter #{options["datacenter"]} Doesn't Exist!" unless get_datacenter(options["datacenter"])
21
+ raise Fog::Compute::Vsphere::NotFound, "Template #{options["template_path"]} Doesn't Exist!" unless get_virtual_machine(options["template_path"], options["datacenter"])
22
+ options
23
+ end
24
+ end
25
+
26
+ class Real
27
+ include Shared
28
+
29
+ # Clones a VM from a template or existing machine on your vSphere
30
+ # Server.
31
+ #
32
+ # ==== Parameters
33
+ # * options<~Hash>:
34
+ # * 'datacenter'<~String> - *REQUIRED* Datacenter name your cloning
35
+ # in. Make sure this datacenter exists, should if you're using
36
+ # the clone function in server.rb model.
37
+ # * 'template_path'<~String> - *REQUIRED* The path to the machine you
38
+ # want to clone FROM. Relative to Datacenter (Example:
39
+ # "FolderNameHere/VMNameHere")
40
+ # * 'name'<~String> - *REQUIRED* The VMName of the Destination
41
+ # * 'dest_folder'<~String> - Destination Folder of where 'name' will
42
+ # be placed on your cluster. Relative Path to Datacenter E.G.
43
+ # "FolderPlaceHere/anotherSub Folder/onemore"
44
+ # * 'power_on'<~Boolean> - Whether to power on machine after clone.
45
+ # Defaults to true.
46
+ # * 'wait'<~Boolean> - Whether the method should wait for the virtual
47
+ # machine to finish cloning before returning information from
48
+ # vSphere. Broken right now as you cannot return a model of a serer
49
+ # that isn't finished cloning. Defaults to True
50
+ # * 'resource_pool'<~Array> - The resource pool on your datacenter
51
+ # cluster you want to use. Only works with clusters within same
52
+ # same datacenter as where you're cloning from. Datacenter grabbed
53
+ # from template_path option.
54
+ # Example: ['cluster_name_here','resource_pool_name_here']
55
+ # * 'datastore'<~String> - The datastore you'd like to use.
56
+ # (datacenterObj.datastoreFolder.find('name') in API)
57
+ # * 'transform'<~String> - Not documented - see http://www.vmware.com/support/developer/vc-sdk/visdk41pubs/ApiReference/vim.vm.RelocateSpec.html
58
+ # * 'numCPUs'<~Integer> - the number of Virtual CPUs of the Destination VM
59
+ # * 'memoryMB'<~Integer> - the size of memory of the Destination VM in MB
60
+ # * customization_spec<~Hash>: Options are marked as required if you
61
+ # use this customization_spec.
62
+ # As defined https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Specification.html
63
+ # * encryptionKey <~array of bytes> Used to encrypt/decrypt password
64
+ # * globalIPSettings expects a hash, REQUIRED
65
+ # * identity expects a hash, REQUIRED - either LinuxPrep, Sysprep or SysprepText
66
+ # * nicSettingMap expects an array
67
+ # * options expects a hash
68
+ # * All options can be parsed using a yaml template with cloudinit_to_customspec.rb
69
+ #
70
+ # OLD Values still supported:
71
+ # This only support cloning and setting DHCP on the first interface
72
+ # * 'domain'<~String> - *REQUIRED* This is put into
73
+ # /etc/resolve.conf (we hope)
74
+ # * 'hostname'<~String> - Hostname of the Guest Os - default is
75
+ # options['name']
76
+ # * 'hw_utc_clock'<~Boolean> - *REQUIRED* Is hardware clock UTC?
77
+ # Default true
78
+ # * 'time_zone'<~String> - *REQUIRED* Only valid linux options
79
+ # are valid - example: 'America/Denver'
80
+ # * 'interfaces' <~Array> - interfaces object to apply to
81
+ # the template when cloning: overrides the
82
+ # network_label, network_adapter_device_key and nic_type attributes
83
+ # * 'volumes' <~Array> - volumes object to apply to
84
+ # the template when cloning: this allows to resize the
85
+ # existing disks as well as add or remove them. The
86
+ # resizing is applied only when the size is bigger then the
87
+ # in size in the template
88
+ def vm_clone(options = {})
89
+ # Option handling
90
+ options = vm_clone_check_options(options)
91
+
92
+ # Added for people still using options['path']
93
+ template_path = options['path'] || options['template_path']
94
+
95
+ # Options['template_path']<~String>
96
+ # Added for people still using options['path']
97
+ template_path = options['path'] || options['template_path']
98
+ # Now find the template itself using the efficient find method
99
+ vm_mob_ref = get_vm_ref(template_path, options['datacenter'])
100
+
101
+ # Options['dest_folder']<~String>
102
+ # Grab the destination folder object if it exists else use cloned mach
103
+ dest_folder_path = options.fetch('dest_folder','/') # default to root path ({dc_name}/vm/)
104
+ dest_folder = get_raw_vmfolder(dest_folder_path, options['datacenter'])
105
+
106
+ # Options['resource_pool']<~Array>
107
+ # Now find _a_ resource pool to use for the clone if one is not specified
108
+ if ( options.key?('resource_pool') && options['resource_pool'].is_a?(Array) && options['resource_pool'].length == 2 )
109
+ cluster_name = options['resource_pool'][0]
110
+ pool_name = options['resource_pool'][1]
111
+ resource_pool = get_raw_resource_pool(pool_name, cluster_name, options['datacenter'])
112
+ elsif ( vm_mob_ref.resourcePool == nil )
113
+ # If the template is really a template then there is no associated resource pool,
114
+ # so we need to find one using the template's parent host or cluster
115
+ esx_host = vm_mob_ref.collect!('runtime.host')['runtime.host']
116
+ # The parent of the ESX host itself is a ComputeResource which has a resourcePool
117
+ resource_pool = esx_host.parent.resourcePool
118
+ end
119
+ # If the vm given did return a valid resource pool, default to using it for the clone.
120
+ # Even if specific pools aren't implemented in this environment, we will still get back
121
+ # at least the cluster or host we can pass on to the clone task
122
+ # This catches if resource_pool option is set but comes back nil and if resourcePool is
123
+ # already set.
124
+ resource_pool ||= vm_mob_ref.resourcePool.nil? ? esx_host.parent.resourcePool : vm_mob_ref.resourcePool
125
+
126
+ # Options['datastore']<~String>
127
+ # Grab the datastore object if option is set
128
+ datastore_obj = get_raw_datastore(options['datastore'], options['datacenter']) if options.key?('datastore')
129
+ # confirm nil if nil or option is not set
130
+ datastore_obj ||= nil
131
+ virtual_machine_config_spec = RbVmomi::VIM::VirtualMachineConfigSpec()
132
+
133
+ device_change = []
134
+ # fully futured interfaces api: replace the current nics
135
+ # with the new based on the specification
136
+ if (options.key?('interfaces') )
137
+ if options.key?('network_label')
138
+ raise ArgumentError, "interfaces option can't be specified together with network_label"
139
+ end
140
+ device_change.concat(modify_template_nics_specs(template_path, options['interfaces'], options['datacenter']))
141
+ elsif options.key?('network_label')
142
+ device_change << modify_template_nics_simple_spec(options['network_label'], options['nic_type'], options['network_adapter_device_key'], options['datacenter'])
143
+ end
144
+ if disks = options['volumes']
145
+ device_change.concat(modify_template_volumes_specs(vm_mob_ref, options['volumes']))
146
+ end
147
+ virtual_machine_config_spec.deviceChange = device_change if device_change.any?
148
+ # Options['numCPUs'] or Options['memoryMB']
149
+ # Build up the specification for Hardware, for more details see ____________
150
+ # https://github.com/rlane/rbvmomi/blob/master/test/test_serialization.rb
151
+ # http://www.vmware.com/support/developer/vc-sdk/visdk41pubs/ApiReference/vim.vm.ConfigSpec.html
152
+ # FIXME: pad this out with the rest of the useful things in VirtualMachineConfigSpec
153
+ virtual_machine_config_spec.numCPUs = options['numCPUs'] if ( options.key?('numCPUs') )
154
+ virtual_machine_config_spec.memoryMB = options['memoryMB'] if ( options.key?('memoryMB') )
155
+ virtual_machine_config_spec.cpuHotAddEnabled = options['cpuHotAddEnabled'] if ( options.key?('cpuHotAddEnabled') )
156
+ virtual_machine_config_spec.memoryHotAddEnabled = options['memoryHotAddEnabled'] if ( options.key?('memoryHotAddEnabled') )
157
+ virtual_machine_config_spec.firmware = options['firmware'] if ( options.key?('firmware') )
158
+ # Options['customization_spec']
159
+ # OLD Options still supported
160
+ # * domain <~String> - *REQUIRED* - Sets the server's domain for customization
161
+ # * dnsSuffixList <~Array> - Optional - Sets the dns search paths in resolv - Example: ["dev.example.com", "example.com"]
162
+ # * time_zone <~String> - Required - Only valid linux options are valid - example: 'America/Denver'
163
+ # * ipsettings <~Hash> - Optional - If not set defaults to dhcp
164
+ # * ip <~String> - *REQUIRED* Sets the ip address of the VM - Example: 10.0.0.10
165
+ # * dnsServerList <~Array> - Optional - Sets the nameservers in resolv - Example: ["10.0.0.2", "10.0.0.3"]
166
+ # * gateway <~Array> - Optional - Sets the gateway for the interface - Example: ["10.0.0.1"]
167
+ # * subnetMask <~String> - *REQUIRED* - Set the netmask of the interface - Example: "255.255.255.0"
168
+ # For other ip settings options see http://www.vmware.com/support/developer/vc-sdk/visdk41pubs/ApiReference/vim.vm.customization.IPSettings.html
169
+ #
170
+ # Implement complete customization spec as per https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Specification.html
171
+ # * encryptionKey <~Array> - Optional, encryption key used to encypt any encrypted passwords
172
+ # https://pubs.vmware.com/vsphere-51/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.GlobalIPSettings.html
173
+ # * globalIPSettings <~Hash> - REQUIRED
174
+ # * dnsServerList <~Array> - Optional, list of dns servers - Example: ["10.0.0.2", "10.0.0.3"]
175
+ # * dnsSuffixList <~Array> - Optional, List of name resolution suffixes - Example: ["dev.example.com", "example.com"]
176
+ # * identity <~Hash> - REQUIRED, Network identity and settings, similar to Microsoft's Sysprep tool. This is a Sysprep, LinuxPrep, or SysprepText object
177
+ # * Sysprep <~Hash> - Optional, representation of a Windows sysprep.inf answer file.
178
+ # * guiRunOnce: <~Hash> -Optional, representation of the sysprep GuiRunOnce key
179
+ # * commandList: <~Array> - REQUIRED, list of commands to run at first user logon, after guest customization. - Example: ["c:\sysprep\runaftersysprep.cmd", "c:\sysprep\installpuppet.ps1"]
180
+ # * guiUnattended: <~Hash> - REQUIRED, representation of the sysprep GuiUnattended key
181
+ # * autoLogin: boolean - REQUIRED, Flag to determine whether or not the machine automatically logs on as Administrator.
182
+ # * autoLogonCount: int - REQUIRED, specifies the number of times the machine should automatically log on as Administrator
183
+ # * password: <~Hash> - REQUIRED, new administrator password for the machine
184
+ # * plainText: boolean - REQUIRED, specify whether or not the password is in plain text, rather than encrypted
185
+ # * value: <~String> - REQUIRED, password string
186
+ # * timeZone: <~int> - REQUIRED, (see here for values https://msdn.microsoft.com/en-us/library/ms912391(v=winembedded.11).aspx)
187
+ # * identification: <~Hash> - REQUIRED, representation of the sysprep Identification key
188
+ # * domainAdmin: <~String> - Optional, domain user account used for authentication if the virtual machine is joining a domain
189
+ # * domainAdminPassword: <~Hash> - Optional, password for the domain user account used for authentication
190
+ # * plainText: boolean - REQUIRED, specify whether or not the password is in plain text, rather than encrypted
191
+ # * value: <~String> - REQUIRED, password string
192
+ # * joinDomain: <~String> - Optional, The domain that the virtual machine should join. If this value is supplied, then domainAdmin and domainAdminPassword must also be supplied
193
+ # * joinWorkgroup: <~String> - Optional, The workgroup that the virtual machine should join.
194
+ # * licenseFilePrintData: <~Hash> - Optional, representation of the sysprep LicenseFilePrintData key
195
+ # * autoMode: <~String> - REQUIRED, Server licensing mode. Two strings are supported: 'perSeat' or 'perServer'
196
+ # * autoUsers: <~Int> - Optional, This key is valid only if AutoMode = PerServer. The integer value indicates the number of client licenses
197
+ # * userData: <~Hash> - REQUIRED, representation of the sysprep UserData key
198
+ # * computerName: <~String> - REQUIRED, The computer name of the (Windows) virtual machine. Will be truncates to 15 characters
199
+ # * fullName: <~String> - REQUIRED, User's full name
200
+ # * orgName: <~String> - REQUIRED, User's organization
201
+ # * productId: <~String> - REQUIRED, serial number for os, ignored if using volume licensed instance
202
+ # * LinuxPrep: <~Hash> - Optional, contains machine-wide settings (note the uppercase P)
203
+ # * domain: <~String> - REQUIRED, The fully qualified domain name.
204
+ # * hostName: <~String> - REQUIRED, the network host name
205
+ # * hwClockUTC: <~Boolean> - Optional, Specifies whether the hardware clock is in UTC or local time
206
+ # * timeZone: <~String> - Optional, Case sensistive timezone, valid values can be found at https://pubs.vmware.com/vsphere-51/topic/com.vmware.wssdk.apiref.doc/timezone.html
207
+ # * SysprepText: <~Hash> - Optional, alternate way to specify the sysprep.inf answer file.
208
+ # * value: <~String> - REQUIRED, Text for the sysprep.inf answer file.
209
+ # * nicSettingMap: <~Array> - Optional, IP settings that are specific to a particular virtual network adapter
210
+ # * Each item in array:
211
+ # * adapter: <~Hash> - REQUIRED, IP settings for the associated virtual network adapter
212
+ # * dnsDomain: <~String> - Optional, DNS domain suffix for adapter
213
+ # * dnsServerList: <~Array> - Optional, list of dns server ip addresses - Example: ["10.0.0.2", "10.0.0.3"]
214
+ # * gateway: <~Array> - Optional, list of gateways - Example: ["10.0.0.2", "10.0.0.3"]
215
+ # * ip: <~String> - Optional, but required if static IP
216
+ # * ipV6Spec: <~Hash> - Optional, IPv^ settings
217
+ # * ipAddress: <~String> - Optional, but required if setting static IP
218
+ # * gateway: <~Array> - Optional, list of ipv6 gateways
219
+ # * netBIOS: <~String> - Optional, NetBIOS settings, if supplied must be one of: disableNetBIOS','enableNetBIOS','enableNetBIOSViaDhcp'
220
+ # * primaryWINS: <~String> - Optional, IP address of primary WINS server
221
+ # * secondaryWINS: <~String> - Optional, IP address of secondary WINS server
222
+ # * subnetMask: <~String> - Optional, subnet mask for adapter
223
+ # * macAddress: <~String> - Optional, MAC address of adapter being customized. This cannot be set by the client
224
+ # * options: <~Hash> Optional operations, currently only win options have any value
225
+ # * changeSID: <~Boolean> - REQUIRED, The customization process should modify the machine's security identifier
226
+ # * deleteAccounts: <~Boolean> - REQUIRED, If deleteAccounts is true, then all user accounts are removed from the system
227
+ # * reboot: <~String> - Optional, (defaults to reboot), Action to be taken after running sysprep, must be one of: 'noreboot', 'reboot', 'shutdown'
228
+ #
229
+ if ( options.key?('customization_spec') )
230
+ custom_spec = options['customization_spec']
231
+
232
+ # backwards compatablity
233
+ if custom_spec.key?('domain')
234
+ # doing this means the old options quash any new ones passed as well... might not be the best way to do it?
235
+ # any 'old' options overwrite the following:
236
+ # - custom_spec['identity']['LinuxPrep']
237
+ # - custom_spec['globalIPSettings['['dnsServerList']
238
+ # - custom_spec['globalIPSettings']['dnsSuffixList']
239
+ # - custom_spec['nicSettingMap'][0]['adapter']['ip']
240
+ # - custom_spec['nicSettingMap'][0]['adapter']['gateway']
241
+ # - custom_spec['nicSettingMap'][0]['adapter']['subnetMask']
242
+ # - custom_spec['nicSettingMap'][0]['adapter']['dnsDomain']
243
+ # - custom_spec['nicSettingMap'][0]['adapter']['dnsServerList']
244
+ #
245
+ # we can assume old parameters being passed
246
+ cust_hostname = custom_spec['hostname'] || options['name']
247
+ custom_spec['identity'] = Hash.new unless custom_spec.key?('identity')
248
+ custom_spec['identity']['LinuxPrep'] = {"domain" => custom_spec['domain'], "hostName" => cust_hostname, "timeZone" => custom_spec['time_zone']}
249
+
250
+ if custom_spec.key?('ipsettings')
251
+ custom_spec['globalIPSettings']=Hash.new unless custom_spec.key?('globalIPSettings')
252
+ custom_spec['globalIPSettings']['dnsServerList'] = custom_spec['ipsettings']['dnsServerList'] if custom_spec['ipsettings'].key?('dnsServerList')
253
+ custom_spec['globalIPSettings']['dnsSuffixList'] = custom_spec['dnsSuffixList'] || [custom_spec['domain']] if ( custom_spec['dnsSuffixList'] || custom_spec['domain'])
254
+ end
255
+
256
+ if (custom_spec['ipsettings'].key?('ip') or custom_spec['ipsettings'].key?('gateway') or custom_spec['ipsettings'].key?('subnetMask') or custom_spec['ipsettings'].key?('domain') or custom_spec['ipsettings'].key?('dnsServerList'))
257
+ if custom_spec['ipsettings'].key?('ip')
258
+ raise ArgumentError, "subnetMask is required for static ip" unless custom_spec["ipsettings"].key?("subnetMask")
259
+ end
260
+ custom_spec['nicSettingMap']=Array.new unless custom_spec.key?('nicSettingMap')
261
+ custom_spec['nicSettingMap'][0]=Hash.new unless custom_spec['nicSettingMap'].length > 0
262
+ custom_spec['nicSettingMap'][0]['adapter']=Hash.new unless custom_spec['nicSettingMap'][0].key?('adapter')
263
+ custom_spec['nicSettingMap'][0]['adapter']['ip'] = custom_spec['ipsettings']['ip'] if custom_spec['ipsettings'].key?('ip')
264
+ custom_spec['nicSettingMap'][0]['adapter']['gateway'] = custom_spec['ipsettings']['gateway'] if custom_spec['ipsettings'].key?('gateway')
265
+ custom_spec['nicSettingMap'][0]['adapter']['subnetMask'] = custom_spec['ipsettings']['subnetMask'] if custom_spec['ipsettings'].key?('subnetMask')
266
+ custom_spec['nicSettingMap'][0]['adapter']['dnsDomain'] = custom_spec['ipsettings']['domain'] if custom_spec['ipsettings'].key?('domain')
267
+ custom_spec['nicSettingMap'][0]['adapter']['dnsServerList'] = custom_spec['ipsettings']['dnsServerList'] if custom_spec['ipsettings'].key?('dnsServerList')
268
+ end
269
+ end
270
+ ### End of backwards compatability
271
+
272
+ ## requirements check here ##
273
+ raise ArgumentError, "globalIPSettings are required when using Customization Spec" unless custom_spec.key?('globalIPSettings')
274
+ raise ArgumentError, "identity is required when using Customization Spec" unless custom_spec.key?('identity')
275
+
276
+ # encryptionKey
277
+ custom_encryptionKey = custom_spec['encryptionKey'] if custom_spec.key?('encryptionKey')
278
+ custom_encryptionKey ||= nil
279
+
280
+ # globalIPSettings
281
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.GlobalIPSettings.html
282
+ custom_globalIPSettings = RbVmomi::VIM::CustomizationGlobalIPSettings.new()
283
+ custom_globalIPSettings.dnsServerList = custom_spec['globalIPSettings']['dnsServerList'] if custom_spec['globalIPSettings'].key?("dnsServerList")
284
+ custom_globalIPSettings.dnsSuffixList = custom_spec['globalIPSettings']['dnsSuffixList'] if custom_spec['globalIPSettings'].key?("dnsSuffixList")
285
+
286
+ # identity
287
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.IdentitySettings.html
288
+ # Accepts the 3 supported CustomizationIdentitySettings Types:
289
+ # 1. CustomizationLinuxPrep (LinuxPrep) - note the uppercase P
290
+ # 2. CustomizationSysprep (Sysprep)
291
+ # 3. CustomizationSysprepText (SysprepText)
292
+ # At least one of these is required
293
+ #
294
+ identity = custom_spec['identity']
295
+ if identity.key?("LinuxPrep")
296
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.LinuxPrep.html
297
+ # Fields:
298
+ # * domain: string **REQUIRED**
299
+ # * hostName: string (CustomizationName) **REQUIRED** Will use options['name'] if not provided.
300
+ # * hwClockUTC: boolean
301
+ # * timeZone: string (https://pubs.vmware.com/vsphere-55/topic/com.vmware.wssdk.apiref.doc/timezone.html)
302
+ raise ArgumentError, "domain is required when using LinuxPrep identity" unless identity['LinuxPrep'].key?('domain')
303
+ custom_identity = RbVmomi::VIM::CustomizationLinuxPrep(:domain => identity['LinuxPrep']['domain'])
304
+ cust_hostname = RbVmomi::VIM::CustomizationFixedName(:name => identity['LinuxPrep']['hostName']) if identity['LinuxPrep'].key?('hostName')
305
+ cust_hostname ||= RbVmomi::VIM::CustomizationFixedName(:name => options['name'])
306
+ custom_identity.hostName = cust_hostname
307
+ custom_identity.hwClockUTC = identity['LinuxPrep']['hwClockUTC'] if identity['LinuxPrep'].key?('hwClockUTC')
308
+ custom_identity.timeZone = identity['LinuxPrep']['timeZone'] if identity['LinuxPrep'].key?('timeZone')
309
+ elsif identity.key?("Sysprep")
310
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Sysprep.html
311
+ # Fields:
312
+ # * guiRunOnce: CustomizationGuiRunOnce
313
+ # * guiUnattended: CustomizationGuiUnattended **REQUIRED**
314
+ # * identification: CustomizationIdentification **REQUIRED**
315
+ # * licenseFilePrintData: CustomizationLicenseFilePrintData
316
+ # * userData: CustomizationUserData **REQUIRED**
317
+ #
318
+ raise ArgumentError, "guiUnattended is required when using Sysprep identity" unless identity['Sysprep'].key?('guiUnattended')
319
+ raise ArgumentError, "identification is required when using Sysprep identity" unless identity['Sysprep'].key?('identification')
320
+ raise ArgumentError, "userData is required when using Sysprep identity" unless identity['Sysprep'].key?('userData')
321
+ if identity['Sysprep']['guiRunOnce']
322
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.GuiRunOnce.html
323
+ # Fields:
324
+ # * commandList: array of string **REQUIRED***
325
+ #
326
+ raise ArgumentError, "commandList is required when using Sysprep identity and guiRunOnce" unless identity['Sysprep']['guiRunOnce'].key?('commandList')
327
+ cust_guirunonce = RbVmomi::VIM.CustomizationGuiRunOnce( :commandList => identity['Sysprep']['guiRunOnce']['commandList'] )
328
+ end
329
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.GuiUnattended.html
330
+ # Fields:
331
+ # * autoLogin: boolean **REQUIRED**
332
+ # * autoLogonCount: int **REQUIRED**
333
+ # * timeZone: int (see here for values https://msdn.microsoft.com/en-us/library/ms912391(v=winembedded.11).aspx) **REQUIRED**
334
+ # * password: CustomizationPassword
335
+ raise ArgumentError, "guiUnattended->autoLogon is required when using Sysprep identity" unless identity['Sysprep']['guiUnattended'].key?('autoLogon')
336
+ raise ArgumentError, "guiUnattended->autoLogonCount is required when using Sysprep identity" unless identity['Sysprep']['guiUnattended'].key?('autoLogonCount')
337
+ raise ArgumentError, "guiUnattended->timeZone is required when using Sysprep identity" unless identity['Sysprep']['guiUnattended'].key?('timeZone')
338
+ custom_guiUnattended = RbVmomi::VIM.CustomizationGuiUnattended(
339
+ :autoLogon => identity['Sysprep']['guiUnattended']['autoLogon'],
340
+ :autoLogonCount => identity['Sysprep']['guiUnattended']['autoLogonCount'],
341
+ :timeZone => identity['Sysprep']['guiUnattended']['timeZone']
342
+ )
343
+ if identity['Sysprep']['guiUnattended']['password']
344
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Password.html
345
+ # Fields:
346
+ # * plainText: boolean **REQUIRED**
347
+ # * value: string **REQUIRED**
348
+ raise ArgumentError, "guiUnattended->password->plainText is required when using Sysprep identity and guiUnattended -> password" unless identity['Sysprep']['guiUnattended']['password'].key?('plainText')
349
+ raise ArgumentError, "guiUnattended->password->value is required when using Sysprep identity and guiUnattended -> password" unless identity['Sysprep']['guiUnattended']['password'].key?('value')
350
+ custom_guiUnattended.password = RbVmomi::VIM.CustomizationPassword(
351
+ :plainText => identity['Sysprep']['guiUnattended']['password']['plainText'],
352
+ :value => identity['Sysprep']['guiUnattended']['password']['value']
353
+ )
354
+ end
355
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Identification.html
356
+ # Fields:
357
+ # * domainAdmin: string
358
+ # * domainAdminPassword: CustomizationPassword
359
+ # * joinDomain: string *If supplied domainAdmin and domainAdminPassword must be set
360
+ # * joinWorkgroup: string *If supplied, joinDomain, domainAdmin and domainAdminPassword will be ignored
361
+ custom_identification = RbVmomi::VIM.CustomizationIdentification()
362
+ if identity['Sysprep']['identification'].key?('joinWorkgroup')
363
+ custom_identification.joinWorkgroup = identity['Sysprep']['identification']['joinWorkgroup']
364
+ elsif identity['Sysprep']['identification'].key?('joinDomain')
365
+ raise ArgumentError, "identification->domainAdmin is required when using Sysprep identity and identification -> joinDomain" unless identity['Sysprep']['identification'].key?('domainAdmin')
366
+ raise ArgumentError, "identification->domainAdminPassword is required when using Sysprep identity and identification -> joinDomain" unless identity['Sysprep']['identification'].key?('domainAdmin')
367
+ raise ArgumentError, "identification->domainAdminPassword->plainText is required when using Sysprep identity and identification -> joinDomain" unless identity['Sysprep']['identification']['domainAdminPassword'].key?('plainText')
368
+ raise ArgumentError, "identification->domainAdminPassword->value is required when using Sysprep identity and identification -> joinDomain" unless identity['Sysprep']['identification']['domainAdminPassword'].key?('value')
369
+ custom_identification.joinDomain = identity['Sysprep']['identification']['joinDomain']
370
+ custom_identification.domainAdmin = identity['Sysprep']['identification']['domainAdmin']
371
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Password.html
372
+ # Fields:
373
+ # * plainText: boolean **REQUIRED**
374
+ # * value: string **REQUIRED**
375
+ custom_identification.domainAdminPassword = RbVmomi::VIM.CustomizationPassword(
376
+ :plainText => identity['Sysprep']['identification']['domainAdminPassword']['plainText'],
377
+ :value => identity['Sysprep']['identification']['domainAdminPassword']['value']
378
+ )
379
+ else
380
+ raise ArgumentError, "No valid Indentification found, valid values are 'joinWorkgroup' and 'joinDomain'"
381
+ end
382
+ if identity['Sysprep'].key?('licenseFilePrintData')
383
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.LicenseFilePrintData.html
384
+ # Fields:
385
+ # * autoMode: string (CustomizationLicenseDataMode) ** REQUIRED **, valid strings are: 'perSeat' or 'perServer'
386
+ # * autoUsers: int (valid only if AutoMode = PerServer)
387
+ raise ArgumentError, "licenseFilePrintData->autoMode is required when using Sysprep identity and licenseFilePrintData" unless identity['Sysprep']['licenseFilePrintData'].key?('autoMode')
388
+ raise ArgumentError, "Unsupported autoMode, supported modes are : 'perSeat' or 'perServer'" unless ['perSeat', 'perServer'].include? identity['Sysprep']['licenseFilePrintData']['autoMode']
389
+ custom_licenseFilePrintData = RbVmomi::VIM.CustomizationLicenseFilePrintData(
390
+ :autoMode => RbVmomi::VIM.CustomizationLicenseDataMode(identity['Sysprep']['licenseFilePrintData']['autoMode'])
391
+ )
392
+ if identity['Sysprep']['licenseFilePrintData'].key?('autoUsers')
393
+ custom_licenseFilePrintData.autoUsers = identity['Sysprep']['licenseFilePrintData']['autoUsers'] if identity['Sysprep']['licenseFilePrintData']['autoMode'] == "PerServer"
394
+ end
395
+ end
396
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.UserData.html
397
+ # Fields:
398
+ # * computerName: string (CustomizationFixedName) **REQUIRED**
399
+ # * fullName: string **REQUIRED**
400
+ # * orgName: string **REQUIRED**
401
+ # * productID: string **REQUIRED**
402
+ raise ArgumentError, "userData->computerName is required when using Sysprep identity" unless identity['Sysprep']['userData'].key?('computerName')
403
+ raise ArgumentError, "userData->fullName is required when using Sysprep identity" unless identity['Sysprep']['userData'].key?('fullName')
404
+ raise ArgumentError, "userData->orgName is required when using Sysprep identity" unless identity['Sysprep']['userData'].key?('orgName')
405
+ raise ArgumentError, "userData->productId is required when using Sysprep identity" unless identity['Sysprep']['userData'].key?('productId')
406
+ custom_userData = RbVmomi::VIM.CustomizationUserData(
407
+ :fullName => identity['Sysprep']['userData']['fullName'],
408
+ :orgName => identity['Sysprep']['userData']['orgName'],
409
+ :productId => identity['Sysprep']['userData']['productId'],
410
+ :computerName => RbVmomi::VIM.CustomizationFixedName(:name => identity['Sysprep']['userData']['computerName'])
411
+ )
412
+
413
+ custom_identity = RbVmomi::VIM::CustomizationSysprep(
414
+ :guiUnattended => custom_guiUnattended,
415
+ :identification => custom_identification,
416
+ :userData => custom_userData
417
+ )
418
+ custom_identity.guiRunOnce = cust_guirunonce if defined?(cust_guirunonce)
419
+ custom_identity.licenseFilePrintData = custom_licenseFilePrintData if defined?(custom_licenseFilePrintData)
420
+ elsif identity.key?("SysprepText")
421
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.SysprepText.html
422
+ # Fields:
423
+ # * value: string **REQUIRED**
424
+ raise ArgumentError, "SysprepText -> value is required when using SysprepText identity" unless identity['SysprepText'].key?('value')
425
+ custom_identity = RbVmomi::VIM::CustomizationSysprepText(:value => identity['SysprepText']['value'])
426
+ else
427
+ raise ArgumentError, "At least one of the following valid identities must be supplied: LinuxPrep, Sysprep, SysprepText"
428
+ end
429
+
430
+ if custom_spec.key?("nicSettingMap")
431
+ # custom_spec['nicSettingMap'] is an array of adapater mappings:
432
+ # custom_spec['nicSettingMap'][0]['macAddress']
433
+ # custom_spec['nicSettingMap'][0]['adapter']['ip']
434
+ #https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.AdapterMapping.html
435
+ # Fields:
436
+ # * adapter: CustomizationIPSettings **REQUIRED**
437
+ # * macAddress: string
438
+ raise ArgumentError, "At least one nicSettingMap is required when using nicSettingMap" unless custom_spec['nicSettingMap'].length > 0
439
+ raise ArgumentError, "Adapter is required when using nicSettingMap" unless custom_spec['nicSettingMap'][0].key?('adapter')
440
+
441
+ custom_nicSettingMap = []
442
+ # need to go through array here for each apapter
443
+ custom_spec['nicSettingMap'].each do | nic |
444
+ # https://pubs.vmware.com/vsphere-55/index.jsp?topic=%2Fcom.vmware.wssdk.apiref.doc%2Fvim.vm.customization.IPSettings.html
445
+ # Fields:
446
+ # * dnsDomain: string
447
+ # * gateway: array of string
448
+ # * ip: CustomizationIpGenerator (string) **REQUIRED IF Assigning Static IP***
449
+ # * ipV6Spec: CustomizationIPSettingsIpV6AddressSpec
450
+ # * netBIOS: CustomizationNetBIOSMode (string)
451
+ # * primaryWINS: string
452
+ # * secondaryWINS: string
453
+ # * subnetMask: string - Required if assigning static IP
454
+ if nic['adapter'].key?('ip')
455
+ raise ArgumentError, "SubnetMask is required when assigning static IP when using nicSettingMap -> Adapter" unless nic['adapter'].key?('subnetMask')
456
+ custom_ip = RbVmomi::VIM.CustomizationFixedIp(:ipAddress => nic['adapter']['ip'])
457
+ else
458
+ custom_ip = RbVmomi::VIM::CustomizationDhcpIpGenerator.new()
459
+ end
460
+ custom_adapter = RbVmomi::VIM.CustomizationIPSettings(:ip => custom_ip)
461
+ custom_adapter.dnsDomain = nic['adapter']['dnsDomain'] if nic['adapter'].key?('dnsDomain')
462
+ custom_adapter.dnsServerList = nic['adapter']['dnsServerList'] if nic['adapter'].key?('dnsServerList')
463
+ custom_adapter.gateway = nic['adapter']['gateway'] if nic['adapter'].key?('gateway')
464
+ if nic['adapter'].key?('ipV6Spec')
465
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.IPSettings.IpV6AddressSpec.html
466
+ # Fields:
467
+ # * gateway: array of string
468
+ # * ip: CustomizationIpV6Generator[] **Required if setting static IP **
469
+ if nic['adapter']['ipV6Spec'].key?('ipAddress')
470
+ raise ArgumentError, "SubnetMask is required when assigning static IPv6 when using nicSettingMap -> Adapter -> ipV6Spec" unless nic['adapter']['ipV6Spec'].key?('subnetMask')
471
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.FixedIpV6.html
472
+ # * ipAddress: string **REQUIRED**
473
+ # * subnetMask: int **REQUIRED**
474
+ custom_ipv6 = RbVmomi::VIM.CustomizationFixedIpV6(
475
+ :ipAddress => nic['adapter']['ipV6Spec']['ipAddress'],
476
+ :subnetMask => nic['adapter']['ipV6Spec']['subnetMask']
477
+ )
478
+ else
479
+ custom_ipv6 = RbVmomi::VIM::CustomizationDhcpIpV6Generator.new()
480
+ end
481
+ custom_ipv6Spec = RbVmomi::VIM.CustomizationIPSettingsIpV6AddressSpec(:ip => custom_ipv6)
482
+ custom_ipv6Spec.gateway = nic['adapter']['ipV6Spec']['gateway'] if nic['adapter']['ipV6Spec'].key?('gateway')
483
+ custom_adapter.ipV6Spec = custom_ipv6Spec
484
+ end
485
+ if nic['adapter'].key?('netBIOS')
486
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.IPSettings.NetBIOSMode.html
487
+ # Fields:
488
+ # netBIOS: string matching: 'disableNetBIOS','enableNetBIOS' or 'enableNetBIOSViaDhcp' ** REQUIRED **
489
+ #
490
+ raise ArgumentError, "Unsupported NetBIOSMode, supported modes are : 'disableNetBIOS','enableNetBIOS' or 'enableNetBIOSViaDhcp'" unless ['disableNetBIOS','enableNetBIOS','enableNetBIOSViaDhcp'].include? nic['adapter']['netBIOS']
491
+ custom_adapter.netBIOS = RbVmomi::VIM.CustomizationNetBIOSMode(nic['adapter']['netBIOS'])
492
+ end
493
+ custom_adapter.primaryWINS = nic['adapter']['primaryWINS'] if nic['adapter'].key?('primaryWINS')
494
+ custom_adapter.secondaryWINS = nic['adapter']['secondaryWINS'] if nic['adapter'].key?('secondaryWINS')
495
+ custom_adapter.subnetMask = nic['adapter']['subnetMask'] if nic['adapter'].key?('subnetMask')
496
+
497
+ custom_adapter_mapping = RbVmomi::VIM::CustomizationAdapterMapping(:adapter => custom_adapter)
498
+ custom_adapter_mapping.macAddress = nic['macAddress'] if nic.key?('macAddress')
499
+
500
+ # build the adapters array, creates it if not already created, otherwise appends to it
501
+ custom_nicSettingMap << custom_adapter_mapping
502
+ end
503
+ end
504
+ custom_nicSettingMap = nil if custom_nicSettingMap.length < 1
505
+
506
+ if custom_spec.key?("options")
507
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Options.html
508
+ # this currently doesn't have any Linux options, just windows
509
+ # Fields:
510
+ # * changeSID: boolean **REQUIRED**
511
+ # * deleteAccounts: boolean **REQUIRED** **note deleteAccounts is deprecated as of VI API 2.5 so can be ignored
512
+ # * reboot: CustomizationSysprepRebootOption: (string) one of following 'noreboot', reboot' or 'shutdown' (defaults to reboot)
513
+ raise ArgumentError, "changeSID id required when using Windows Options" unless custom_spec['options'].key?('changeSID')
514
+ raise ArgumentError, "deleteAccounts id required when using Windows Options" unless custom_spec['options'].key?('deleteAccounts')
515
+ custom_options = RbVmomi::VIM::CustomizationWinOptions(
516
+ :changeSID => custom_spec['options']['changeSID'],
517
+ :deleteAccounts => custom_spec['options']['deleteAccounts']
518
+ )
519
+ if custom_spec['options'].key?('reboot')
520
+ raise ArgumentError, "Unsupported reboot option, supported options are : 'noreboot', 'reboot' or 'shutdown'" unless ['noreboot','reboot','shutdown'].include? custom_spec['options']['reboot']
521
+ custom_options.reboot = RBVmomi::VIM.CustomizationSysprepRebootOption(custom_spec['options']['reboot'])
522
+ end
523
+ end
524
+ custom_options ||=nil
525
+
526
+ # https://pubs.vmware.com/vsphere-55/index.jsp#com.vmware.wssdk.apiref.doc/vim.vm.customization.Specification.html
527
+ customization_spec = RbVmomi::VIM::CustomizationSpec(
528
+ :globalIPSettings => custom_globalIPSettings,
529
+ :identity => custom_identity
530
+ )
531
+ customization_spec.encryptionKey = custom_encryptionKey if defined?(custom_encryptionKey)
532
+ customization_spec.nicSettingMap = custom_nicSettingMap if defined?(custom_nicSettingMap)
533
+ customization_spec.options = custom_options if defined?(custom_options)
534
+
535
+ end
536
+ customization_spec ||= nil
537
+
538
+ relocation_spec=nil
539
+ if ( options['linked_clone'] )
540
+ # cribbed heavily from the rbvmomi clone_vm.rb
541
+ # this chunk of code reconfigures the disk of the clone source to be read only,
542
+ # and then creates a delta disk on top of that, this is required by the API in order to create
543
+ # linked clondes
544
+ disks = vm_mob_ref.config.hardware.device.select do |vm_device|
545
+ vm_device.class == RbVmomi::VIM::VirtualDisk
546
+ end
547
+ disks.select{|vm_device| vm_device.backing.parent == nil}.each do |disk|
548
+ disk_spec = {
549
+ :deviceChange => [
550
+ {
551
+ :operation => :remove,
552
+ :device => disk
553
+ },
554
+ {
555
+ :operation => :add,
556
+ :fileOperation => :create,
557
+ :device => disk.dup.tap{|disk_backing|
558
+ disk_backing.backing = disk_backing.backing.dup;
559
+ disk_backing.backing.fileName = "[#{disk.backing.datastore.name}]";
560
+ disk_backing.backing.parent = disk.backing
561
+ }
562
+ }
563
+ ]
564
+ }
565
+ vm_mob_ref.ReconfigVM_Task(:spec => disk_spec).wait_for_completion
566
+ end
567
+ # Next, create a Relocation Spec instance
568
+ relocation_spec = RbVmomi::VIM.VirtualMachineRelocateSpec(:datastore => datastore_obj,
569
+ :pool => resource_pool,
570
+ :diskMoveType => :moveChildMostDiskBacking)
571
+ else
572
+ relocation_spec = RbVmomi::VIM.VirtualMachineRelocateSpec(:datastore => datastore_obj,
573
+ :pool => resource_pool,
574
+ :transform => options['transform'] || 'sparse')
575
+ end
576
+ # And the clone specification
577
+ clone_spec = RbVmomi::VIM.VirtualMachineCloneSpec(:location => relocation_spec,
578
+ :config => virtual_machine_config_spec,
579
+ :customization => customization_spec,
580
+ :powerOn => options.key?('power_on') ? options['power_on'] : true,
581
+ :template => false)
582
+
583
+ # Perform the actual Clone Task
584
+ task = vm_mob_ref.CloneVM_Task(:folder => dest_folder,
585
+ :name => options['name'],
586
+ :spec => clone_spec)
587
+ # Waiting for the VM to complete allows us to get the VirtulMachine
588
+ # object of the new machine when it's done. It is HIGHLY recommended
589
+ # to set 'wait' => true if your app wants to wait. Otherwise, you're
590
+ # going to have to reload the server model over and over which
591
+ # generates a lot of time consuming API calls to vmware.
592
+ if options.fetch('wait', true) then
593
+ # REVISIT: It would be awesome to call a block passed to this
594
+ # request to notify the application how far along in the process we
595
+ # are. I'm thinking of updating a progress bar, etc...
596
+ new_vm = task.wait_for_completion
597
+ else
598
+ tries = 0
599
+ new_vm = begin
600
+ # Try and find the new VM (folder.find is quite efficient)
601
+ dest_folder.find(options['name'], RbVmomi::VIM::VirtualMachine) or raise Fog::Vsphere::Errors::NotFound
602
+ rescue Fog::Vsphere::Errors::NotFound
603
+ tries += 1
604
+ if tries <= 10 then
605
+ sleep 15
606
+ retry
607
+ end
608
+ nil
609
+ end
610
+ end
611
+
612
+ # Return hash
613
+ {
614
+ 'vm_ref' => new_vm ? new_vm._ref : nil,
615
+ 'new_vm' => new_vm ? convert_vm_mob_ref_to_attr_hash(new_vm) : nil,
616
+ 'task_ref' => task._ref
617
+ }
618
+ end
619
+
620
+ # Build up the network config spec for simple case:
621
+ # simple case: apply just the network_label, nic_type and network_adapter_device_key
622
+ def modify_template_nics_simple_spec(network_label, nic_type, network_adapter_device_key, datacenter)
623
+ config_spec_operation = RbVmomi::VIM::VirtualDeviceConfigSpecOperation('edit')
624
+ # Get the portgroup and handle it from there.
625
+ network = get_raw_network(network_label, datacenter)
626
+ if ( network.kind_of? RbVmomi::VIM::DistributedVirtualPortgroup)
627
+ # Create the NIC backing for the distributed virtual portgroup
628
+ nic_backing_info = RbVmomi::VIM::VirtualEthernetCardDistributedVirtualPortBackingInfo(
629
+ :port => RbVmomi::VIM::DistributedVirtualSwitchPortConnection(
630
+ :portgroupKey => network.key,
631
+ :switchUuid => network.config.distributedVirtualSwitch.uuid
632
+ )
633
+ )
634
+ else
635
+ # Otherwise it's a non distributed port group
636
+ nic_backing_info = RbVmomi::VIM::VirtualEthernetCardNetworkBackingInfo(:deviceName => network_label)
637
+ end
638
+ connectable = RbVmomi::VIM::VirtualDeviceConnectInfo(
639
+ :allowGuestControl => true,
640
+ :connected => true,
641
+ :startConnected => true)
642
+ device = RbVmomi::VIM.public_send "#{nic_type}",
643
+ :backing => nic_backing_info,
644
+ :deviceInfo => RbVmomi::VIM::Description(:label => "Network adapter 1", :summary => network_label),
645
+ :key => network_adapter_device_key,
646
+ :connectable => connectable
647
+ device_spec = RbVmomi::VIM::VirtualDeviceConfigSpec(
648
+ :operation => config_spec_operation,
649
+ :device => device)
650
+ return device_spec
651
+ end
652
+
653
+
654
+ def modify_template_nics_specs(template_path, new_nics, datacenter)
655
+ #new_spec_operation = RbVmomi::VIM::VirtualDeviceConfigSpecOperation('new')
656
+ #remove_spec_operation = RbVmomi::VIM::VirtualDeviceConfigSpecOperation('remove')
657
+
658
+ template_nics = list_vm_interfaces(template_path, datacenter).map do |old_attributes|
659
+ Fog::Compute::Vsphere::Interface.new(old_attributes)
660
+ end
661
+ specs = []
662
+
663
+ template_nics.each do |interface|
664
+ specs << create_interface(interface, interface.key, :remove)
665
+ end
666
+
667
+ new_nics.each do |interface|
668
+ specs << create_interface(interface, 0, :add)
669
+ end
670
+
671
+ return specs
672
+ end
673
+
674
+ def modify_template_volumes_specs(vm_mob_ref, volumes)
675
+ template_volumes = vm_mob_ref.config.hardware.device.grep(RbVmomi::VIM::VirtualDisk)
676
+ modified_volumes = volumes.take(template_volumes.size)
677
+ new_volumes = volumes.drop(template_volumes.size)
678
+
679
+ specs = []
680
+ template_volumes.zip(modified_volumes).each do |template_volume, new_volume|
681
+ if new_volume
682
+ # updated the attribtues on the existing volume
683
+ # it's not allowed to reduce the size of the volume when cloning
684
+ if new_volume.size > template_volume.capacityInKB
685
+ template_volume.capacityInKB = new_volume.size
686
+ end
687
+ template_volume.backing.diskMode = new_volume.mode
688
+ template_volume.backing.thinProvisioned = new_volume.thin
689
+ specs << { :operation => :edit, :device => template_volume }
690
+ else
691
+ specs << { :operation => :remove,
692
+ :fileOperation => :destroy,
693
+ :device => template_volume }
694
+ end
695
+ end
696
+ specs.concat(new_volumes.map { |volume| create_disk(volume, volumes.index(volume)) })
697
+ return specs
698
+ end
699
+ end
700
+
701
+ class Mock
702
+ include Shared
703
+ def vm_clone(options = {})
704
+ # Option handling TODO Needs better method of checking
705
+ options = vm_clone_check_options(options)
706
+ notfound = lambda { raise Fog::Compute::Vsphere::NotFound, "Could not find VM template" }
707
+ template = list_virtual_machines.find(notfound) do |vm|
708
+ vm['name'] == options['template_path'].split("/")[-1]
709
+ end
710
+
711
+ # generate a random id
712
+ id = [8,4,4,4,12].map{|i| Fog::Mock.random_hex(i)}.join("-")
713
+ new_vm = template.clone.merge({
714
+ "name" => options['name'],
715
+ "id" => id,
716
+ "instance_uuid" => id,
717
+ "path" => "/Datacenters/#{options['datacenter']}/#{options['dest_folder'] ? options['dest_folder']+"/" : ""}#{options['name']}"
718
+ })
719
+ self.data[:servers][id] = new_vm
720
+
721
+ {
722
+ 'vm_ref' => "vm-#{Fog::Mock.random_numbers(3)}",
723
+ 'new_vm' => new_vm,
724
+ 'task_ref' => "task-#{Fog::Mock.random_numbers(4)}",
725
+ }
726
+ end
727
+ end
728
+ end
729
+ end
730
+ end