fog-zj 0.1.28

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1157) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +13 -0
  3. data/.hound.yml +2 -0
  4. data/.rubocop.yml +110 -0
  5. data/.ruby-gemset +1 -0
  6. data/.travis.yml +32 -0
  7. data/.zuul.yaml +35 -0
  8. data/CHANGELOG.md +47 -0
  9. data/CODE_OF_CONDUCT.md +49 -0
  10. data/CONTRIBUTING.md +18 -0
  11. data/Gemfile +4 -0
  12. data/LICENSE.md +20 -0
  13. data/README.md +572 -0
  14. data/Rakefile +31 -0
  15. data/bin/console +14 -0
  16. data/bin/setup +8 -0
  17. data/docker-compose.yml +44 -0
  18. data/docs/common/connection_params.md +45 -0
  19. data/docs/common/resources.md +11 -0
  20. data/docs/compute.md +636 -0
  21. data/docs/getting_started.md +82 -0
  22. data/docs/introspection.md +251 -0
  23. data/docs/metering.md +43 -0
  24. data/docs/network.md +238 -0
  25. data/docs/nfv.md +144 -0
  26. data/docs/orchestration.md +360 -0
  27. data/docs/planning.md +225 -0
  28. data/docs/shared_file_system.md +82 -0
  29. data/docs/storage.md +406 -0
  30. data/docs/workflow.md +131 -0
  31. data/examples/compute/basics.rb +50 -0
  32. data/examples/compute/block_device_mapping_v2.rb +30 -0
  33. data/examples/container_infra/basics.rb +61 -0
  34. data/examples/event/basics.rb +22 -0
  35. data/examples/identity/basics.rb +67 -0
  36. data/examples/identity/basics_v3.rb +83 -0
  37. data/examples/image/upload-test-image.rb +74 -0
  38. data/examples/introspection/basics.rb +75 -0
  39. data/examples/metric/basics.rb +42 -0
  40. data/examples/network/network_add_port.rb +21 -0
  41. data/examples/network/network_rbac.rb +69 -0
  42. data/examples/network/network_subnets_routers.rb +62 -0
  43. data/examples/planning/basics.rb +53 -0
  44. data/examples/shared_file_system/basics.rb +68 -0
  45. data/examples/storage/set-account-quota.rb +64 -0
  46. data/examples/volume/backups.rb +41 -0
  47. data/examples/workflow/workflow-examples.rb +387 -0
  48. data/fog-openstack.gemspec +38 -0
  49. data/lib/fog/baremetal/openstack.rb +284 -0
  50. data/lib/fog/baremetal/openstack/models/chassis.rb +49 -0
  51. data/lib/fog/baremetal/openstack/models/chassis_collection.rb +44 -0
  52. data/lib/fog/baremetal/openstack/models/driver.rb +24 -0
  53. data/lib/fog/baremetal/openstack/models/drivers.rb +21 -0
  54. data/lib/fog/baremetal/openstack/models/node.rb +96 -0
  55. data/lib/fog/baremetal/openstack/models/nodes.rb +44 -0
  56. data/lib/fog/baremetal/openstack/models/port.rb +50 -0
  57. data/lib/fog/baremetal/openstack/models/ports.rb +44 -0
  58. data/lib/fog/baremetal/openstack/requests/create_chassis.rb +44 -0
  59. data/lib/fog/baremetal/openstack/requests/create_node.rb +54 -0
  60. data/lib/fog/baremetal/openstack/requests/create_port.rb +46 -0
  61. data/lib/fog/baremetal/openstack/requests/delete_chassis.rb +25 -0
  62. data/lib/fog/baremetal/openstack/requests/delete_node.rb +25 -0
  63. data/lib/fog/baremetal/openstack/requests/delete_port.rb +25 -0
  64. data/lib/fog/baremetal/openstack/requests/get_chassis.rb +24 -0
  65. data/lib/fog/baremetal/openstack/requests/get_driver.rb +24 -0
  66. data/lib/fog/baremetal/openstack/requests/get_driver_properties.rb +40 -0
  67. data/lib/fog/baremetal/openstack/requests/get_node.rb +24 -0
  68. data/lib/fog/baremetal/openstack/requests/get_port.rb +24 -0
  69. data/lib/fog/baremetal/openstack/requests/list_chassis.rb +42 -0
  70. data/lib/fog/baremetal/openstack/requests/list_chassis_detailed.rb +25 -0
  71. data/lib/fog/baremetal/openstack/requests/list_drivers.rb +25 -0
  72. data/lib/fog/baremetal/openstack/requests/list_nodes.rb +34 -0
  73. data/lib/fog/baremetal/openstack/requests/list_nodes_detailed.rb +25 -0
  74. data/lib/fog/baremetal/openstack/requests/list_ports.rb +42 -0
  75. data/lib/fog/baremetal/openstack/requests/list_ports_detailed.rb +25 -0
  76. data/lib/fog/baremetal/openstack/requests/patch_chassis.rb +41 -0
  77. data/lib/fog/baremetal/openstack/requests/patch_node.rb +41 -0
  78. data/lib/fog/baremetal/openstack/requests/patch_port.rb +41 -0
  79. data/lib/fog/baremetal/openstack/requests/set_node_maintenance.rb +30 -0
  80. data/lib/fog/baremetal/openstack/requests/set_node_power_state.rb +35 -0
  81. data/lib/fog/baremetal/openstack/requests/set_node_provision_state.rb +38 -0
  82. data/lib/fog/baremetal/openstack/requests/unset_node_maintenance.rb +30 -0
  83. data/lib/fog/compute/openstack.rb +413 -0
  84. data/lib/fog/compute/openstack/models/address.rb +67 -0
  85. data/lib/fog/compute/openstack/models/addresses.rb +28 -0
  86. data/lib/fog/compute/openstack/models/aggregate.rb +59 -0
  87. data/lib/fog/compute/openstack/models/aggregates.rb +26 -0
  88. data/lib/fog/compute/openstack/models/availability_zone.rb +19 -0
  89. data/lib/fog/compute/openstack/models/availability_zones.rb +22 -0
  90. data/lib/fog/compute/openstack/models/flavor.rb +64 -0
  91. data/lib/fog/compute/openstack/models/flavors.rb +29 -0
  92. data/lib/fog/compute/openstack/models/host.rb +28 -0
  93. data/lib/fog/compute/openstack/models/hosts.rb +26 -0
  94. data/lib/fog/compute/openstack/models/image.rb +47 -0
  95. data/lib/fog/compute/openstack/models/images.rb +38 -0
  96. data/lib/fog/compute/openstack/models/key_pair.rb +56 -0
  97. data/lib/fog/compute/openstack/models/key_pairs.rb +29 -0
  98. data/lib/fog/compute/openstack/models/metadata.rb +65 -0
  99. data/lib/fog/compute/openstack/models/metadatum.rb +27 -0
  100. data/lib/fog/compute/openstack/models/network.rb +13 -0
  101. data/lib/fog/compute/openstack/models/networks.rb +30 -0
  102. data/lib/fog/compute/openstack/models/os_interface.rb +15 -0
  103. data/lib/fog/compute/openstack/models/os_interfaces.rb +28 -0
  104. data/lib/fog/compute/openstack/models/security_group.rb +57 -0
  105. data/lib/fog/compute/openstack/models/security_group_rule.rb +32 -0
  106. data/lib/fog/compute/openstack/models/security_group_rules.rb +21 -0
  107. data/lib/fog/compute/openstack/models/security_groups.rb +24 -0
  108. data/lib/fog/compute/openstack/models/server.rb +410 -0
  109. data/lib/fog/compute/openstack/models/server_group.rb +22 -0
  110. data/lib/fog/compute/openstack/models/server_groups.rb +28 -0
  111. data/lib/fog/compute/openstack/models/servers.rb +59 -0
  112. data/lib/fog/compute/openstack/models/service.rb +42 -0
  113. data/lib/fog/compute/openstack/models/services.rb +35 -0
  114. data/lib/fog/compute/openstack/models/snapshot.rb +32 -0
  115. data/lib/fog/compute/openstack/models/snapshots.rb +37 -0
  116. data/lib/fog/compute/openstack/models/tenant.rb +24 -0
  117. data/lib/fog/compute/openstack/models/tenants.rb +24 -0
  118. data/lib/fog/compute/openstack/models/volume.rb +52 -0
  119. data/lib/fog/compute/openstack/models/volume_attachment.rb +15 -0
  120. data/lib/fog/compute/openstack/models/volume_attachments.rb +20 -0
  121. data/lib/fog/compute/openstack/models/volumes.rb +37 -0
  122. data/lib/fog/compute/openstack/requests/add_aggregate_host.rb +30 -0
  123. data/lib/fog/compute/openstack/requests/add_fixed_ip.rb +29 -0
  124. data/lib/fog/compute/openstack/requests/add_flavor_access.rb +29 -0
  125. data/lib/fog/compute/openstack/requests/add_security_group.rb +20 -0
  126. data/lib/fog/compute/openstack/requests/allocate_address.rb +39 -0
  127. data/lib/fog/compute/openstack/requests/associate_address.rb +30 -0
  128. data/lib/fog/compute/openstack/requests/attach_volume.rb +39 -0
  129. data/lib/fog/compute/openstack/requests/boot_from_snapshot.rb +41 -0
  130. data/lib/fog/compute/openstack/requests/change_server_password.rb +20 -0
  131. data/lib/fog/compute/openstack/requests/confirm_resize_server.rb +20 -0
  132. data/lib/fog/compute/openstack/requests/create_aggregate.rb +42 -0
  133. data/lib/fog/compute/openstack/requests/create_flavor.rb +85 -0
  134. data/lib/fog/compute/openstack/requests/create_flavor_metadata.rb +37 -0
  135. data/lib/fog/compute/openstack/requests/create_image.rb +44 -0
  136. data/lib/fog/compute/openstack/requests/create_key_pair.rb +48 -0
  137. data/lib/fog/compute/openstack/requests/create_os_interface.rb +42 -0
  138. data/lib/fog/compute/openstack/requests/create_security_group.rb +51 -0
  139. data/lib/fog/compute/openstack/requests/create_security_group_rule.rb +57 -0
  140. data/lib/fog/compute/openstack/requests/create_server.rb +187 -0
  141. data/lib/fog/compute/openstack/requests/create_server_group.rb +31 -0
  142. data/lib/fog/compute/openstack/requests/create_snapshot.rb +51 -0
  143. data/lib/fog/compute/openstack/requests/create_volume.rb +58 -0
  144. data/lib/fog/compute/openstack/requests/delete_aggregate.rb +28 -0
  145. data/lib/fog/compute/openstack/requests/delete_flavor.rb +28 -0
  146. data/lib/fog/compute/openstack/requests/delete_flavor_metadata.rb +30 -0
  147. data/lib/fog/compute/openstack/requests/delete_image.rb +36 -0
  148. data/lib/fog/compute/openstack/requests/delete_key_pair.rb +31 -0
  149. data/lib/fog/compute/openstack/requests/delete_meta.rb +35 -0
  150. data/lib/fog/compute/openstack/requests/delete_metadata.rb +23 -0
  151. data/lib/fog/compute/openstack/requests/delete_os_interface.rb +24 -0
  152. data/lib/fog/compute/openstack/requests/delete_security_group.rb +31 -0
  153. data/lib/fog/compute/openstack/requests/delete_security_group_rule.rb +31 -0
  154. data/lib/fog/compute/openstack/requests/delete_server.rb +40 -0
  155. data/lib/fog/compute/openstack/requests/delete_server_group.rb +28 -0
  156. data/lib/fog/compute/openstack/requests/delete_service.rb +32 -0
  157. data/lib/fog/compute/openstack/requests/delete_snapshot.rb +28 -0
  158. data/lib/fog/compute/openstack/requests/delete_volume.rb +28 -0
  159. data/lib/fog/compute/openstack/requests/detach_volume.rb +29 -0
  160. data/lib/fog/compute/openstack/requests/disable_service.rb +37 -0
  161. data/lib/fog/compute/openstack/requests/disable_service_log_reason.rb +38 -0
  162. data/lib/fog/compute/openstack/requests/disassociate_address.rb +25 -0
  163. data/lib/fog/compute/openstack/requests/enable_service.rb +37 -0
  164. data/lib/fog/compute/openstack/requests/evacuate_server.rb +26 -0
  165. data/lib/fog/compute/openstack/requests/get_address.rb +38 -0
  166. data/lib/fog/compute/openstack/requests/get_aggregate.rb +25 -0
  167. data/lib/fog/compute/openstack/requests/get_console_output.rb +24 -0
  168. data/lib/fog/compute/openstack/requests/get_flavor_details.rb +39 -0
  169. data/lib/fog/compute/openstack/requests/get_flavor_metadata.rb +26 -0
  170. data/lib/fog/compute/openstack/requests/get_host_details.rb +60 -0
  171. data/lib/fog/compute/openstack/requests/get_hypervisor.rb +64 -0
  172. data/lib/fog/compute/openstack/requests/get_hypervisor_statistics.rb +39 -0
  173. data/lib/fog/compute/openstack/requests/get_image_details.rb +29 -0
  174. data/lib/fog/compute/openstack/requests/get_key_pair.rb +50 -0
  175. data/lib/fog/compute/openstack/requests/get_limits.rb +94 -0
  176. data/lib/fog/compute/openstack/requests/get_metadata.rb +24 -0
  177. data/lib/fog/compute/openstack/requests/get_os_interface.rb +24 -0
  178. data/lib/fog/compute/openstack/requests/get_quota.rb +26 -0
  179. data/lib/fog/compute/openstack/requests/get_quota_defaults.rb +26 -0
  180. data/lib/fog/compute/openstack/requests/get_security_group.rb +37 -0
  181. data/lib/fog/compute/openstack/requests/get_security_group_rule.rb +38 -0
  182. data/lib/fog/compute/openstack/requests/get_server_details.rb +29 -0
  183. data/lib/fog/compute/openstack/requests/get_server_group.rb +38 -0
  184. data/lib/fog/compute/openstack/requests/get_server_password.rb +29 -0
  185. data/lib/fog/compute/openstack/requests/get_server_volumes.rb +27 -0
  186. data/lib/fog/compute/openstack/requests/get_snapshot_details.rb +30 -0
  187. data/lib/fog/compute/openstack/requests/get_usage.rb +48 -0
  188. data/lib/fog/compute/openstack/requests/get_vnc_console.rb +49 -0
  189. data/lib/fog/compute/openstack/requests/get_volume_details.rb +32 -0
  190. data/lib/fog/compute/openstack/requests/list_address_pools.rb +28 -0
  191. data/lib/fog/compute/openstack/requests/list_addresses.rb +29 -0
  192. data/lib/fog/compute/openstack/requests/list_aggregates.rb +37 -0
  193. data/lib/fog/compute/openstack/requests/list_all_addresses.rb +62 -0
  194. data/lib/fog/compute/openstack/requests/list_availability_zones.rb +23 -0
  195. data/lib/fog/compute/openstack/requests/list_flavors.rb +35 -0
  196. data/lib/fog/compute/openstack/requests/list_flavors_detail.rb +35 -0
  197. data/lib/fog/compute/openstack/requests/list_hosts.rb +27 -0
  198. data/lib/fog/compute/openstack/requests/list_hypervisor_servers.rb +42 -0
  199. data/lib/fog/compute/openstack/requests/list_hypervisors.rb +27 -0
  200. data/lib/fog/compute/openstack/requests/list_hypervisors_detail.rb +71 -0
  201. data/lib/fog/compute/openstack/requests/list_images.rb +29 -0
  202. data/lib/fog/compute/openstack/requests/list_images_detail.rb +36 -0
  203. data/lib/fog/compute/openstack/requests/list_key_pairs.rb +39 -0
  204. data/lib/fog/compute/openstack/requests/list_metadata.rb +24 -0
  205. data/lib/fog/compute/openstack/requests/list_os_interfaces.rb +24 -0
  206. data/lib/fog/compute/openstack/requests/list_private_addresses.rb +29 -0
  207. data/lib/fog/compute/openstack/requests/list_public_addresses.rb +29 -0
  208. data/lib/fog/compute/openstack/requests/list_security_groups.rb +67 -0
  209. data/lib/fog/compute/openstack/requests/list_server_groups.rb +28 -0
  210. data/lib/fog/compute/openstack/requests/list_servers.rb +36 -0
  211. data/lib/fog/compute/openstack/requests/list_servers_detail.rb +43 -0
  212. data/lib/fog/compute/openstack/requests/list_services.rb +66 -0
  213. data/lib/fog/compute/openstack/requests/list_snapshots.rb +40 -0
  214. data/lib/fog/compute/openstack/requests/list_snapshots_detail.rb +26 -0
  215. data/lib/fog/compute/openstack/requests/list_tenants.rb +43 -0
  216. data/lib/fog/compute/openstack/requests/list_tenants_with_flavor_access.rb +26 -0
  217. data/lib/fog/compute/openstack/requests/list_usages.rb +38 -0
  218. data/lib/fog/compute/openstack/requests/list_volume_attachments.rb +31 -0
  219. data/lib/fog/compute/openstack/requests/list_volumes.rb +39 -0
  220. data/lib/fog/compute/openstack/requests/list_volumes_detail.rb +25 -0
  221. data/lib/fog/compute/openstack/requests/list_zones.rb +33 -0
  222. data/lib/fog/compute/openstack/requests/list_zones_detailed.rb +68 -0
  223. data/lib/fog/compute/openstack/requests/live_migrate_server.rb +26 -0
  224. data/lib/fog/compute/openstack/requests/migrate_server.rb +20 -0
  225. data/lib/fog/compute/openstack/requests/pause_server.rb +24 -0
  226. data/lib/fog/compute/openstack/requests/reboot_server.rb +20 -0
  227. data/lib/fog/compute/openstack/requests/rebuild_server.rb +34 -0
  228. data/lib/fog/compute/openstack/requests/release_address.rb +29 -0
  229. data/lib/fog/compute/openstack/requests/remote_consoles.rb +54 -0
  230. data/lib/fog/compute/openstack/requests/remove_aggregate_host.rb +30 -0
  231. data/lib/fog/compute/openstack/requests/remove_fixed_ip.rb +29 -0
  232. data/lib/fog/compute/openstack/requests/remove_flavor_access.rb +29 -0
  233. data/lib/fog/compute/openstack/requests/remove_security_group.rb +20 -0
  234. data/lib/fog/compute/openstack/requests/rescue_server.rb +24 -0
  235. data/lib/fog/compute/openstack/requests/reset_server_state.rb +20 -0
  236. data/lib/fog/compute/openstack/requests/resize_server.rb +20 -0
  237. data/lib/fog/compute/openstack/requests/resume_server.rb +24 -0
  238. data/lib/fog/compute/openstack/requests/revert_resize_server.rb +26 -0
  239. data/lib/fog/compute/openstack/requests/server_action.rb +16 -0
  240. data/lib/fog/compute/openstack/requests/server_actions.rb +38 -0
  241. data/lib/fog/compute/openstack/requests/server_diagnostics.rb +25 -0
  242. data/lib/fog/compute/openstack/requests/set_metadata.rb +37 -0
  243. data/lib/fog/compute/openstack/requests/set_tenant.rb +19 -0
  244. data/lib/fog/compute/openstack/requests/shelve_offload_server.rb +24 -0
  245. data/lib/fog/compute/openstack/requests/shelve_server.rb +24 -0
  246. data/lib/fog/compute/openstack/requests/start_server.rb +24 -0
  247. data/lib/fog/compute/openstack/requests/stop_server.rb +24 -0
  248. data/lib/fog/compute/openstack/requests/suspend_server.rb +24 -0
  249. data/lib/fog/compute/openstack/requests/unpause_server.rb +24 -0
  250. data/lib/fog/compute/openstack/requests/unshelve_server.rb +24 -0
  251. data/lib/fog/compute/openstack/requests/update_aggregate.rb +37 -0
  252. data/lib/fog/compute/openstack/requests/update_aggregate_metadata.rb +30 -0
  253. data/lib/fog/compute/openstack/requests/update_flavor_metadata.rb +33 -0
  254. data/lib/fog/compute/openstack/requests/update_meta.rb +38 -0
  255. data/lib/fog/compute/openstack/requests/update_metadata.rb +38 -0
  256. data/lib/fog/compute/openstack/requests/update_quota.rb +27 -0
  257. data/lib/fog/compute/openstack/requests/update_server.rb +32 -0
  258. data/lib/fog/container_infra/openstack.rb +163 -0
  259. data/lib/fog/container_infra/openstack/models/base.rb +19 -0
  260. data/lib/fog/container_infra/openstack/models/bay.rb +56 -0
  261. data/lib/fog/container_infra/openstack/models/bay_model.rb +62 -0
  262. data/lib/fog/container_infra/openstack/models/bay_models.rb +23 -0
  263. data/lib/fog/container_infra/openstack/models/bays.rb +23 -0
  264. data/lib/fog/container_infra/openstack/models/certificate.rb +20 -0
  265. data/lib/fog/container_infra/openstack/models/certificates.rb +25 -0
  266. data/lib/fog/container_infra/openstack/models/cluster.rb +56 -0
  267. data/lib/fog/container_infra/openstack/models/cluster_template.rb +61 -0
  268. data/lib/fog/container_infra/openstack/models/cluster_templates.rb +24 -0
  269. data/lib/fog/container_infra/openstack/models/clusters.rb +24 -0
  270. data/lib/fog/container_infra/openstack/requests/create_bay.rb +27 -0
  271. data/lib/fog/container_infra/openstack/requests/create_bay_model.rb +56 -0
  272. data/lib/fog/container_infra/openstack/requests/create_certificate.rb +29 -0
  273. data/lib/fog/container_infra/openstack/requests/create_cluster.rb +27 -0
  274. data/lib/fog/container_infra/openstack/requests/create_cluster_template.rb +56 -0
  275. data/lib/fog/container_infra/openstack/requests/delete_bay.rb +24 -0
  276. data/lib/fog/container_infra/openstack/requests/delete_bay_model.rb +24 -0
  277. data/lib/fog/container_infra/openstack/requests/delete_cluster.rb +24 -0
  278. data/lib/fog/container_infra/openstack/requests/delete_cluster_template.rb +24 -0
  279. data/lib/fog/container_infra/openstack/requests/get_bay.rb +51 -0
  280. data/lib/fog/container_infra/openstack/requests/get_bay_model.rb +55 -0
  281. data/lib/fog/container_infra/openstack/requests/get_certificate.rb +27 -0
  282. data/lib/fog/container_infra/openstack/requests/get_cluster.rb +41 -0
  283. data/lib/fog/container_infra/openstack/requests/get_cluster_template.rb +55 -0
  284. data/lib/fog/container_infra/openstack/requests/list_bay_models.rb +69 -0
  285. data/lib/fog/container_infra/openstack/requests/list_bays.rb +55 -0
  286. data/lib/fog/container_infra/openstack/requests/list_cluster_templates.rb +59 -0
  287. data/lib/fog/container_infra/openstack/requests/list_clusters.rb +37 -0
  288. data/lib/fog/container_infra/openstack/requests/update_bay.rb +27 -0
  289. data/lib/fog/container_infra/openstack/requests/update_bay_model.rb +56 -0
  290. data/lib/fog/container_infra/openstack/requests/update_cluster.rb +27 -0
  291. data/lib/fog/container_infra/openstack/requests/update_cluster_template.rb +56 -0
  292. data/lib/fog/dns/openstack.rb +21 -0
  293. data/lib/fog/dns/openstack/v1.rb +128 -0
  294. data/lib/fog/dns/openstack/v1/requests/get_quota.rb +26 -0
  295. data/lib/fog/dns/openstack/v1/requests/list_domains.rb +27 -0
  296. data/lib/fog/dns/openstack/v1/requests/update_quota.rb +31 -0
  297. data/lib/fog/dns/openstack/v2.rb +342 -0
  298. data/lib/fog/dns/openstack/v2/models/pool.rb +21 -0
  299. data/lib/fog/dns/openstack/v2/models/pools.rb +25 -0
  300. data/lib/fog/dns/openstack/v2/models/recordset.rb +55 -0
  301. data/lib/fog/dns/openstack/v2/models/recordsets.rb +30 -0
  302. data/lib/fog/dns/openstack/v2/models/zone.rb +50 -0
  303. data/lib/fog/dns/openstack/v2/models/zone_transfer_accept.rb +29 -0
  304. data/lib/fog/dns/openstack/v2/models/zone_transfer_accepts.rb +25 -0
  305. data/lib/fog/dns/openstack/v2/models/zone_transfer_request.rb +50 -0
  306. data/lib/fog/dns/openstack/v2/models/zone_transfer_requests.rb +30 -0
  307. data/lib/fog/dns/openstack/v2/models/zones.rb +30 -0
  308. data/lib/fog/dns/openstack/v2/requests/create_recordset.rb +54 -0
  309. data/lib/fog/dns/openstack/v2/requests/create_zone.rb +49 -0
  310. data/lib/fog/dns/openstack/v2/requests/create_zone_transfer_accept.rb +35 -0
  311. data/lib/fog/dns/openstack/v2/requests/create_zone_transfer_request.rb +34 -0
  312. data/lib/fog/dns/openstack/v2/requests/delete_recordset.rb +36 -0
  313. data/lib/fog/dns/openstack/v2/requests/delete_zone.rb +35 -0
  314. data/lib/fog/dns/openstack/v2/requests/delete_zone_transfer_request.rb +26 -0
  315. data/lib/fog/dns/openstack/v2/requests/get_pool.rb +30 -0
  316. data/lib/fog/dns/openstack/v2/requests/get_quota.rb +29 -0
  317. data/lib/fog/dns/openstack/v2/requests/get_recordset.rb +36 -0
  318. data/lib/fog/dns/openstack/v2/requests/get_zone.rb +30 -0
  319. data/lib/fog/dns/openstack/v2/requests/get_zone_transfer_accept.rb +28 -0
  320. data/lib/fog/dns/openstack/v2/requests/get_zone_transfer_request.rb +29 -0
  321. data/lib/fog/dns/openstack/v2/requests/list_pools.rb +30 -0
  322. data/lib/fog/dns/openstack/v2/requests/list_recordsets.rb +54 -0
  323. data/lib/fog/dns/openstack/v2/requests/list_zone_transfer_accepts.rb +27 -0
  324. data/lib/fog/dns/openstack/v2/requests/list_zone_transfer_requests.rb +27 -0
  325. data/lib/fog/dns/openstack/v2/requests/list_zones.rb +30 -0
  326. data/lib/fog/dns/openstack/v2/requests/update_quota.rb +34 -0
  327. data/lib/fog/dns/openstack/v2/requests/update_recordset.rb +40 -0
  328. data/lib/fog/dns/openstack/v2/requests/update_zone.rb +39 -0
  329. data/lib/fog/dns/openstack/v2/requests/update_zone_transfer_request.rb +36 -0
  330. data/lib/fog/event/openstack.rb +120 -0
  331. data/lib/fog/event/openstack/models/event.rb +16 -0
  332. data/lib/fog/event/openstack/models/events.rb +23 -0
  333. data/lib/fog/event/openstack/requests/get_event.rb +27 -0
  334. data/lib/fog/event/openstack/requests/list_events.rb +42 -0
  335. data/lib/fog/identity/openstack.rb +117 -0
  336. data/lib/fog/identity/openstack/v2.rb +181 -0
  337. data/lib/fog/identity/openstack/v2/models/ec2_credential.rb +39 -0
  338. data/lib/fog/identity/openstack/v2/models/ec2_credentials.rb +56 -0
  339. data/lib/fog/identity/openstack/v2/models/role.rb +53 -0
  340. data/lib/fog/identity/openstack/v2/models/roles.rb +22 -0
  341. data/lib/fog/identity/openstack/v2/models/tenant.rb +63 -0
  342. data/lib/fog/identity/openstack/v2/models/tenants.rb +32 -0
  343. data/lib/fog/identity/openstack/v2/models/user.rb +69 -0
  344. data/lib/fog/identity/openstack/v2/models/users.rb +45 -0
  345. data/lib/fog/identity/openstack/v2/requests/add_user_to_tenant.rb +36 -0
  346. data/lib/fog/identity/openstack/v2/requests/check_token.rb +22 -0
  347. data/lib/fog/identity/openstack/v2/requests/create_ec2_credential.rb +59 -0
  348. data/lib/fog/identity/openstack/v2/requests/create_role.rb +38 -0
  349. data/lib/fog/identity/openstack/v2/requests/create_tenant.rb +34 -0
  350. data/lib/fog/identity/openstack/v2/requests/create_user.rb +45 -0
  351. data/lib/fog/identity/openstack/v2/requests/create_user_role.rb +26 -0
  352. data/lib/fog/identity/openstack/v2/requests/delete_ec2_credential.rb +43 -0
  353. data/lib/fog/identity/openstack/v2/requests/delete_role.rb +30 -0
  354. data/lib/fog/identity/openstack/v2/requests/delete_tenant.rb +33 -0
  355. data/lib/fog/identity/openstack/v2/requests/delete_user.rb +31 -0
  356. data/lib/fog/identity/openstack/v2/requests/delete_user_role.rb +25 -0
  357. data/lib/fog/identity/openstack/v2/requests/get_ec2_credential.rb +50 -0
  358. data/lib/fog/identity/openstack/v2/requests/get_role.rb +30 -0
  359. data/lib/fog/identity/openstack/v2/requests/get_tenant.rb +33 -0
  360. data/lib/fog/identity/openstack/v2/requests/get_tenants_by_id.rb +20 -0
  361. data/lib/fog/identity/openstack/v2/requests/get_tenants_by_name.rb +20 -0
  362. data/lib/fog/identity/openstack/v2/requests/get_user_by_id.rb +34 -0
  363. data/lib/fog/identity/openstack/v2/requests/get_user_by_name.rb +29 -0
  364. data/lib/fog/identity/openstack/v2/requests/list_ec2_credentials.rb +61 -0
  365. data/lib/fog/identity/openstack/v2/requests/list_endpoints_for_token.rb +20 -0
  366. data/lib/fog/identity/openstack/v2/requests/list_roles.rb +34 -0
  367. data/lib/fog/identity/openstack/v2/requests/list_roles_for_user_on_tenant.rb +32 -0
  368. data/lib/fog/identity/openstack/v2/requests/list_tenants.rb +53 -0
  369. data/lib/fog/identity/openstack/v2/requests/list_user_global_roles.rb +20 -0
  370. data/lib/fog/identity/openstack/v2/requests/list_users.rb +47 -0
  371. data/lib/fog/identity/openstack/v2/requests/remove_user_from_tenant.rb +22 -0
  372. data/lib/fog/identity/openstack/v2/requests/set_tenant.rb +21 -0
  373. data/lib/fog/identity/openstack/v2/requests/update_tenant.rb +30 -0
  374. data/lib/fog/identity/openstack/v2/requests/update_user.rb +34 -0
  375. data/lib/fog/identity/openstack/v2/requests/validate_token.rb +22 -0
  376. data/lib/fog/identity/openstack/v3.rb +162 -0
  377. data/lib/fog/identity/openstack/v3/models/domain.rb +59 -0
  378. data/lib/fog/identity/openstack/v3/models/domains.rb +63 -0
  379. data/lib/fog/identity/openstack/v3/models/endpoint.rb +47 -0
  380. data/lib/fog/identity/openstack/v3/models/endpoints.rb +27 -0
  381. data/lib/fog/identity/openstack/v3/models/group.rb +94 -0
  382. data/lib/fog/identity/openstack/v3/models/groups.rb +32 -0
  383. data/lib/fog/identity/openstack/v3/models/os_credential.rb +74 -0
  384. data/lib/fog/identity/openstack/v3/models/os_credentials.rb +32 -0
  385. data/lib/fog/identity/openstack/v3/models/policies.rb +32 -0
  386. data/lib/fog/identity/openstack/v3/models/policy.rb +43 -0
  387. data/lib/fog/identity/openstack/v3/models/project.rb +116 -0
  388. data/lib/fog/identity/openstack/v3/models/projects.rb +75 -0
  389. data/lib/fog/identity/openstack/v3/models/role.rb +41 -0
  390. data/lib/fog/identity/openstack/v3/models/role_assignment.rb +21 -0
  391. data/lib/fog/identity/openstack/v3/models/role_assignments.rb +25 -0
  392. data/lib/fog/identity/openstack/v3/models/roles.rb +40 -0
  393. data/lib/fog/identity/openstack/v3/models/service.rb +48 -0
  394. data/lib/fog/identity/openstack/v3/models/services.rb +32 -0
  395. data/lib/fog/identity/openstack/v3/models/token.rb +24 -0
  396. data/lib/fog/identity/openstack/v3/models/tokens.rb +40 -0
  397. data/lib/fog/identity/openstack/v3/models/user.rb +82 -0
  398. data/lib/fog/identity/openstack/v3/models/users.rb +36 -0
  399. data/lib/fog/identity/openstack/v3/requests/add_user_to_group.rb +20 -0
  400. data/lib/fog/identity/openstack/v3/requests/auth_domains.rb +23 -0
  401. data/lib/fog/identity/openstack/v3/requests/auth_projects.rb +23 -0
  402. data/lib/fog/identity/openstack/v3/requests/check_domain_group_role.rb +20 -0
  403. data/lib/fog/identity/openstack/v3/requests/check_domain_user_role.rb +20 -0
  404. data/lib/fog/identity/openstack/v3/requests/check_project_group_role.rb +20 -0
  405. data/lib/fog/identity/openstack/v3/requests/check_project_user_role.rb +20 -0
  406. data/lib/fog/identity/openstack/v3/requests/create_domain.rb +21 -0
  407. data/lib/fog/identity/openstack/v3/requests/create_endpoint.rb +21 -0
  408. data/lib/fog/identity/openstack/v3/requests/create_group.rb +21 -0
  409. data/lib/fog/identity/openstack/v3/requests/create_os_credential.rb +21 -0
  410. data/lib/fog/identity/openstack/v3/requests/create_policy.rb +21 -0
  411. data/lib/fog/identity/openstack/v3/requests/create_project.rb +21 -0
  412. data/lib/fog/identity/openstack/v3/requests/create_role.rb +21 -0
  413. data/lib/fog/identity/openstack/v3/requests/create_service.rb +21 -0
  414. data/lib/fog/identity/openstack/v3/requests/create_user.rb +21 -0
  415. data/lib/fog/identity/openstack/v3/requests/delete_domain.rb +20 -0
  416. data/lib/fog/identity/openstack/v3/requests/delete_endpoint.rb +20 -0
  417. data/lib/fog/identity/openstack/v3/requests/delete_group.rb +20 -0
  418. data/lib/fog/identity/openstack/v3/requests/delete_os_credential.rb +20 -0
  419. data/lib/fog/identity/openstack/v3/requests/delete_policy.rb +20 -0
  420. data/lib/fog/identity/openstack/v3/requests/delete_project.rb +20 -0
  421. data/lib/fog/identity/openstack/v3/requests/delete_role.rb +20 -0
  422. data/lib/fog/identity/openstack/v3/requests/delete_service.rb +20 -0
  423. data/lib/fog/identity/openstack/v3/requests/delete_user.rb +20 -0
  424. data/lib/fog/identity/openstack/v3/requests/get_domain.rb +22 -0
  425. data/lib/fog/identity/openstack/v3/requests/get_endpoint.rb +22 -0
  426. data/lib/fog/identity/openstack/v3/requests/get_group.rb +22 -0
  427. data/lib/fog/identity/openstack/v3/requests/get_os_credential.rb +22 -0
  428. data/lib/fog/identity/openstack/v3/requests/get_policy.rb +22 -0
  429. data/lib/fog/identity/openstack/v3/requests/get_project.rb +22 -0
  430. data/lib/fog/identity/openstack/v3/requests/get_role.rb +22 -0
  431. data/lib/fog/identity/openstack/v3/requests/get_service.rb +22 -0
  432. data/lib/fog/identity/openstack/v3/requests/get_user.rb +22 -0
  433. data/lib/fog/identity/openstack/v3/requests/grant_domain_group_role.rb +20 -0
  434. data/lib/fog/identity/openstack/v3/requests/grant_domain_user_role.rb +20 -0
  435. data/lib/fog/identity/openstack/v3/requests/grant_project_group_role.rb +20 -0
  436. data/lib/fog/identity/openstack/v3/requests/grant_project_user_role.rb +20 -0
  437. data/lib/fog/identity/openstack/v3/requests/group_user_check.rb +20 -0
  438. data/lib/fog/identity/openstack/v3/requests/list_domain_group_roles.rb +22 -0
  439. data/lib/fog/identity/openstack/v3/requests/list_domain_user_roles.rb +22 -0
  440. data/lib/fog/identity/openstack/v3/requests/list_domains.rb +23 -0
  441. data/lib/fog/identity/openstack/v3/requests/list_endpoints.rb +23 -0
  442. data/lib/fog/identity/openstack/v3/requests/list_group_users.rb +23 -0
  443. data/lib/fog/identity/openstack/v3/requests/list_groups.rb +31 -0
  444. data/lib/fog/identity/openstack/v3/requests/list_os_credentials.rb +23 -0
  445. data/lib/fog/identity/openstack/v3/requests/list_policies.rb +23 -0
  446. data/lib/fog/identity/openstack/v3/requests/list_project_group_roles.rb +22 -0
  447. data/lib/fog/identity/openstack/v3/requests/list_project_user_roles.rb +22 -0
  448. data/lib/fog/identity/openstack/v3/requests/list_projects.rb +30 -0
  449. data/lib/fog/identity/openstack/v3/requests/list_role_assignments.rb +38 -0
  450. data/lib/fog/identity/openstack/v3/requests/list_roles.rb +23 -0
  451. data/lib/fog/identity/openstack/v3/requests/list_services.rb +23 -0
  452. data/lib/fog/identity/openstack/v3/requests/list_user_groups.rb +22 -0
  453. data/lib/fog/identity/openstack/v3/requests/list_user_projects.rb +23 -0
  454. data/lib/fog/identity/openstack/v3/requests/list_users.rb +23 -0
  455. data/lib/fog/identity/openstack/v3/requests/remove_user_from_group.rb +20 -0
  456. data/lib/fog/identity/openstack/v3/requests/revoke_domain_group_role.rb +20 -0
  457. data/lib/fog/identity/openstack/v3/requests/revoke_domain_user_role.rb +20 -0
  458. data/lib/fog/identity/openstack/v3/requests/revoke_project_group_role.rb +20 -0
  459. data/lib/fog/identity/openstack/v3/requests/revoke_project_user_role.rb +20 -0
  460. data/lib/fog/identity/openstack/v3/requests/token_authenticate.rb +21 -0
  461. data/lib/fog/identity/openstack/v3/requests/token_check.rb +21 -0
  462. data/lib/fog/identity/openstack/v3/requests/token_revoke.rb +21 -0
  463. data/lib/fog/identity/openstack/v3/requests/token_validate.rb +21 -0
  464. data/lib/fog/identity/openstack/v3/requests/update_domain.rb +21 -0
  465. data/lib/fog/identity/openstack/v3/requests/update_endpoint.rb +21 -0
  466. data/lib/fog/identity/openstack/v3/requests/update_group.rb +21 -0
  467. data/lib/fog/identity/openstack/v3/requests/update_os_credential.rb +21 -0
  468. data/lib/fog/identity/openstack/v3/requests/update_policy.rb +21 -0
  469. data/lib/fog/identity/openstack/v3/requests/update_project.rb +21 -0
  470. data/lib/fog/identity/openstack/v3/requests/update_role.rb +21 -0
  471. data/lib/fog/identity/openstack/v3/requests/update_service.rb +21 -0
  472. data/lib/fog/identity/openstack/v3/requests/update_user.rb +21 -0
  473. data/lib/fog/image/openstack.rb +23 -0
  474. data/lib/fog/image/openstack/v1.rb +133 -0
  475. data/lib/fog/image/openstack/v1/models/image.rb +78 -0
  476. data/lib/fog/image/openstack/v1/models/images.rb +106 -0
  477. data/lib/fog/image/openstack/v1/requests/add_member_to_image.rb +25 -0
  478. data/lib/fog/image/openstack/v1/requests/create_image.rb +78 -0
  479. data/lib/fog/image/openstack/v1/requests/delete_image.rb +25 -0
  480. data/lib/fog/image/openstack/v1/requests/get_image.rb +47 -0
  481. data/lib/fog/image/openstack/v1/requests/get_image_by_id.rb +44 -0
  482. data/lib/fog/image/openstack/v1/requests/get_image_members.rb +31 -0
  483. data/lib/fog/image/openstack/v1/requests/get_shared_images.rb +31 -0
  484. data/lib/fog/image/openstack/v1/requests/list_public_images.rb +36 -0
  485. data/lib/fog/image/openstack/v1/requests/list_public_images_detailed.rb +37 -0
  486. data/lib/fog/image/openstack/v1/requests/remove_member_from_image.rb +25 -0
  487. data/lib/fog/image/openstack/v1/requests/set_tenant.rb +21 -0
  488. data/lib/fog/image/openstack/v1/requests/update_image.rb +66 -0
  489. data/lib/fog/image/openstack/v1/requests/update_image_members.rb +39 -0
  490. data/lib/fog/image/openstack/v2.rb +141 -0
  491. data/lib/fog/image/openstack/v2/models/image.rb +214 -0
  492. data/lib/fog/image/openstack/v2/models/images.rb +66 -0
  493. data/lib/fog/image/openstack/v2/requests/add_member_to_image.rb +26 -0
  494. data/lib/fog/image/openstack/v2/requests/add_tag_to_image.rb +25 -0
  495. data/lib/fog/image/openstack/v2/requests/create_image.rb +51 -0
  496. data/lib/fog/image/openstack/v2/requests/deactivate_image.rb +25 -0
  497. data/lib/fog/image/openstack/v2/requests/delete_image.rb +25 -0
  498. data/lib/fog/image/openstack/v2/requests/download_image.rb +29 -0
  499. data/lib/fog/image/openstack/v2/requests/get_image.rb +47 -0
  500. data/lib/fog/image/openstack/v2/requests/get_image_by_id.rb +35 -0
  501. data/lib/fog/image/openstack/v2/requests/get_image_members.rb +31 -0
  502. data/lib/fog/image/openstack/v2/requests/get_member_details.rb +33 -0
  503. data/lib/fog/image/openstack/v2/requests/get_shared_images.rb +31 -0
  504. data/lib/fog/image/openstack/v2/requests/list_images.rb +36 -0
  505. data/lib/fog/image/openstack/v2/requests/reactivate_image.rb +25 -0
  506. data/lib/fog/image/openstack/v2/requests/remove_member_from_image.rb +25 -0
  507. data/lib/fog/image/openstack/v2/requests/remove_tag_from_image.rb +25 -0
  508. data/lib/fog/image/openstack/v2/requests/set_tenant.rb +21 -0
  509. data/lib/fog/image/openstack/v2/requests/update_image.rb +49 -0
  510. data/lib/fog/image/openstack/v2/requests/update_image_member.rb +34 -0
  511. data/lib/fog/image/openstack/v2/requests/upload_image.rb +30 -0
  512. data/lib/fog/introspection/openstack.rb +103 -0
  513. data/lib/fog/introspection/openstack/models/rules.rb +29 -0
  514. data/lib/fog/introspection/openstack/models/rules_collection.rb +32 -0
  515. data/lib/fog/introspection/openstack/requests/abort_introspection.rb +25 -0
  516. data/lib/fog/introspection/openstack/requests/create_introspection.rb +35 -0
  517. data/lib/fog/introspection/openstack/requests/create_rules.rb +37 -0
  518. data/lib/fog/introspection/openstack/requests/delete_rules.rb +23 -0
  519. data/lib/fog/introspection/openstack/requests/delete_rules_all.rb +23 -0
  520. data/lib/fog/introspection/openstack/requests/get_introspection.rb +24 -0
  521. data/lib/fog/introspection/openstack/requests/get_introspection_details.rb +24 -0
  522. data/lib/fog/introspection/openstack/requests/get_rules.rb +24 -0
  523. data/lib/fog/introspection/openstack/requests/list_rules.rb +24 -0
  524. data/lib/fog/key_manager/openstack.rb +151 -0
  525. data/lib/fog/key_manager/openstack/models/acl.rb +23 -0
  526. data/lib/fog/key_manager/openstack/models/container.rb +44 -0
  527. data/lib/fog/key_manager/openstack/models/containers.rb +25 -0
  528. data/lib/fog/key_manager/openstack/models/secret.rb +53 -0
  529. data/lib/fog/key_manager/openstack/models/secrets.rb +25 -0
  530. data/lib/fog/key_manager/openstack/requests/create_container.rb +19 -0
  531. data/lib/fog/key_manager/openstack/requests/create_secret.rb +19 -0
  532. data/lib/fog/key_manager/openstack/requests/delete_container.rb +18 -0
  533. data/lib/fog/key_manager/openstack/requests/delete_container_acl.rb +24 -0
  534. data/lib/fog/key_manager/openstack/requests/delete_secret.rb +18 -0
  535. data/lib/fog/key_manager/openstack/requests/delete_secret_acl.rb +24 -0
  536. data/lib/fog/key_manager/openstack/requests/get_container.rb +18 -0
  537. data/lib/fog/key_manager/openstack/requests/get_container_acl.rb +31 -0
  538. data/lib/fog/key_manager/openstack/requests/get_secret.rb +18 -0
  539. data/lib/fog/key_manager/openstack/requests/get_secret_acl.rb +31 -0
  540. data/lib/fog/key_manager/openstack/requests/get_secret_metadata.rb +18 -0
  541. data/lib/fog/key_manager/openstack/requests/get_secret_payload.rb +21 -0
  542. data/lib/fog/key_manager/openstack/requests/list_containers.rb +19 -0
  543. data/lib/fog/key_manager/openstack/requests/list_secrets.rb +19 -0
  544. data/lib/fog/key_manager/openstack/requests/replace_container_acl.rb +27 -0
  545. data/lib/fog/key_manager/openstack/requests/replace_secret_acl.rb +27 -0
  546. data/lib/fog/key_manager/openstack/requests/update_container_acl.rb +26 -0
  547. data/lib/fog/key_manager/openstack/requests/update_secret_acl.rb +26 -0
  548. data/lib/fog/metering/openstack.rb +132 -0
  549. data/lib/fog/metering/openstack/models/event.rb +16 -0
  550. data/lib/fog/metering/openstack/models/events.rb +23 -0
  551. data/lib/fog/metering/openstack/models/meter.rb +0 -0
  552. data/lib/fog/metering/openstack/models/meters.rb +0 -0
  553. data/lib/fog/metering/openstack/models/resource.rb +15 -0
  554. data/lib/fog/metering/openstack/models/resources.rb +23 -0
  555. data/lib/fog/metering/openstack/requests/get_event.rb +27 -0
  556. data/lib/fog/metering/openstack/requests/get_resource.rb +29 -0
  557. data/lib/fog/metering/openstack/requests/get_samples.rb +52 -0
  558. data/lib/fog/metering/openstack/requests/get_statistics.rb +52 -0
  559. data/lib/fog/metering/openstack/requests/list_events.rb +42 -0
  560. data/lib/fog/metering/openstack/requests/list_meters.rb +46 -0
  561. data/lib/fog/metering/openstack/requests/list_resources.rb +29 -0
  562. data/lib/fog/metric/openstack.rb +126 -0
  563. data/lib/fog/metric/openstack/models/metric.rb +18 -0
  564. data/lib/fog/metric/openstack/models/metrics.rb +31 -0
  565. data/lib/fog/metric/openstack/models/resource.rb +16 -0
  566. data/lib/fog/metric/openstack/models/resources.rb +24 -0
  567. data/lib/fog/metric/openstack/requests/get_metric.rb +62 -0
  568. data/lib/fog/metric/openstack/requests/get_metric_measures.rb +38 -0
  569. data/lib/fog/metric/openstack/requests/get_resource.rb +37 -0
  570. data/lib/fog/metric/openstack/requests/get_resource_metric_measures.rb +46 -0
  571. data/lib/fog/metric/openstack/requests/list_metrics.rb +104 -0
  572. data/lib/fog/metric/openstack/requests/list_resources.rb +70 -0
  573. data/lib/fog/monitoring/openstack.rb +96 -0
  574. data/lib/fog/monitoring/openstack/models/alarm.rb +47 -0
  575. data/lib/fog/monitoring/openstack/models/alarm_count.rb +17 -0
  576. data/lib/fog/monitoring/openstack/models/alarm_counts.rb +16 -0
  577. data/lib/fog/monitoring/openstack/models/alarm_definition.rb +57 -0
  578. data/lib/fog/monitoring/openstack/models/alarm_definitions.rb +42 -0
  579. data/lib/fog/monitoring/openstack/models/alarm_state.rb +32 -0
  580. data/lib/fog/monitoring/openstack/models/alarm_states.rb +20 -0
  581. data/lib/fog/monitoring/openstack/models/alarms.rb +30 -0
  582. data/lib/fog/monitoring/openstack/models/dimension_value.rb +19 -0
  583. data/lib/fog/monitoring/openstack/models/dimension_values.rb +16 -0
  584. data/lib/fog/monitoring/openstack/models/measurement.rb +20 -0
  585. data/lib/fog/monitoring/openstack/models/measurements.rb +16 -0
  586. data/lib/fog/monitoring/openstack/models/metric.rb +27 -0
  587. data/lib/fog/monitoring/openstack/models/metrics.rb +36 -0
  588. data/lib/fog/monitoring/openstack/models/notification_method.rb +47 -0
  589. data/lib/fog/monitoring/openstack/models/notification_methods.rb +42 -0
  590. data/lib/fog/monitoring/openstack/models/statistic.rb +20 -0
  591. data/lib/fog/monitoring/openstack/models/statistics.rb +16 -0
  592. data/lib/fog/monitoring/openstack/requests/create_alarm_definition.rb +19 -0
  593. data/lib/fog/monitoring/openstack/requests/create_metric.rb +29 -0
  594. data/lib/fog/monitoring/openstack/requests/create_metric_array.rb +19 -0
  595. data/lib/fog/monitoring/openstack/requests/create_notification_method.rb +19 -0
  596. data/lib/fog/monitoring/openstack/requests/delete_alarm.rb +18 -0
  597. data/lib/fog/monitoring/openstack/requests/delete_alarm_definition.rb +18 -0
  598. data/lib/fog/monitoring/openstack/requests/delete_notification_method.rb +18 -0
  599. data/lib/fog/monitoring/openstack/requests/find_measurements.rb +22 -0
  600. data/lib/fog/monitoring/openstack/requests/get_alarm.rb +21 -0
  601. data/lib/fog/monitoring/openstack/requests/get_alarm_counts.rb +22 -0
  602. data/lib/fog/monitoring/openstack/requests/get_alarm_definition.rb +18 -0
  603. data/lib/fog/monitoring/openstack/requests/get_notification_method.rb +18 -0
  604. data/lib/fog/monitoring/openstack/requests/list_alarm_definitions.rb +22 -0
  605. data/lib/fog/monitoring/openstack/requests/list_alarm_state_history_for_all_alarms.rb +22 -0
  606. data/lib/fog/monitoring/openstack/requests/list_alarm_state_history_for_specific_alarm.rb +22 -0
  607. data/lib/fog/monitoring/openstack/requests/list_alarms.rb +22 -0
  608. data/lib/fog/monitoring/openstack/requests/list_dimension_values.rb +21 -0
  609. data/lib/fog/monitoring/openstack/requests/list_metric_names.rb +22 -0
  610. data/lib/fog/monitoring/openstack/requests/list_metrics.rb +22 -0
  611. data/lib/fog/monitoring/openstack/requests/list_notification_method_types.rb +21 -0
  612. data/lib/fog/monitoring/openstack/requests/list_notification_methods.rb +22 -0
  613. data/lib/fog/monitoring/openstack/requests/list_statistics.rb +22 -0
  614. data/lib/fog/monitoring/openstack/requests/patch_alarm.rb +19 -0
  615. data/lib/fog/monitoring/openstack/requests/patch_alarm_definition.rb +19 -0
  616. data/lib/fog/monitoring/openstack/requests/patch_notification_method.rb +19 -0
  617. data/lib/fog/monitoring/openstack/requests/put_notification_method.rb +19 -0
  618. data/lib/fog/monitoring/openstack/requests/update_alarm.rb +19 -0
  619. data/lib/fog/monitoring/openstack/requests/update_alarm_definition.rb +19 -0
  620. data/lib/fog/network/openstack.rb +479 -0
  621. data/lib/fog/network/openstack/models/extension.rb +15 -0
  622. data/lib/fog/network/openstack/models/extensions.rb +32 -0
  623. data/lib/fog/network/openstack/models/floating_ip.rb +64 -0
  624. data/lib/fog/network/openstack/models/floating_ips.rb +32 -0
  625. data/lib/fog/network/openstack/models/ike_policies.rb +32 -0
  626. data/lib/fog/network/openstack/models/ike_policy.rb +43 -0
  627. data/lib/fog/network/openstack/models/ipsec_policies.rb +32 -0
  628. data/lib/fog/network/openstack/models/ipsec_policy.rb +45 -0
  629. data/lib/fog/network/openstack/models/ipsec_site_connection.rb +51 -0
  630. data/lib/fog/network/openstack/models/ipsec_site_connections.rb +33 -0
  631. data/lib/fog/network/openstack/models/lb_health_monitor.rb +57 -0
  632. data/lib/fog/network/openstack/models/lb_health_monitors.rb +32 -0
  633. data/lib/fog/network/openstack/models/lb_member.rb +42 -0
  634. data/lib/fog/network/openstack/models/lb_members.rb +32 -0
  635. data/lib/fog/network/openstack/models/lb_pool.rb +67 -0
  636. data/lib/fog/network/openstack/models/lb_pools.rb +32 -0
  637. data/lib/fog/network/openstack/models/lb_vip.rb +48 -0
  638. data/lib/fog/network/openstack/models/lb_vips.rb +32 -0
  639. data/lib/fog/network/openstack/models/network.rb +43 -0
  640. data/lib/fog/network/openstack/models/network_ip_availabilities.rb +24 -0
  641. data/lib/fog/network/openstack/models/network_ip_availability.rb +17 -0
  642. data/lib/fog/network/openstack/models/networks.rb +32 -0
  643. data/lib/fog/network/openstack/models/port.rb +42 -0
  644. data/lib/fog/network/openstack/models/ports.rb +32 -0
  645. data/lib/fog/network/openstack/models/rbac_policies.rb +33 -0
  646. data/lib/fog/network/openstack/models/rbac_policy.rb +34 -0
  647. data/lib/fog/network/openstack/models/router.rb +61 -0
  648. data/lib/fog/network/openstack/models/routers.rb +32 -0
  649. data/lib/fog/network/openstack/models/security_group.rb +37 -0
  650. data/lib/fog/network/openstack/models/security_group_rule.rb +33 -0
  651. data/lib/fog/network/openstack/models/security_group_rules.rb +32 -0
  652. data/lib/fog/network/openstack/models/security_groups.rb +32 -0
  653. data/lib/fog/network/openstack/models/subnet.rb +44 -0
  654. data/lib/fog/network/openstack/models/subnet_pool.rb +47 -0
  655. data/lib/fog/network/openstack/models/subnet_pools.rb +33 -0
  656. data/lib/fog/network/openstack/models/subnets.rb +32 -0
  657. data/lib/fog/network/openstack/models/vpn_service.rb +42 -0
  658. data/lib/fog/network/openstack/models/vpn_services.rb +32 -0
  659. data/lib/fog/network/openstack/requests/add_router_interface.rb +52 -0
  660. data/lib/fog/network/openstack/requests/associate_floating_ip.rb +47 -0
  661. data/lib/fog/network/openstack/requests/associate_lb_health_monitor.rb +37 -0
  662. data/lib/fog/network/openstack/requests/create_floating_ip.rb +45 -0
  663. data/lib/fog/network/openstack/requests/create_ike_policy.rb +52 -0
  664. data/lib/fog/network/openstack/requests/create_ipsec_policy.rb +52 -0
  665. data/lib/fog/network/openstack/requests/create_ipsec_site_connection.rb +65 -0
  666. data/lib/fog/network/openstack/requests/create_lb_health_monitor.rb +54 -0
  667. data/lib/fog/network/openstack/requests/create_lb_member.rb +51 -0
  668. data/lib/fog/network/openstack/requests/create_lb_pool.rb +58 -0
  669. data/lib/fog/network/openstack/requests/create_lb_vip.rb +58 -0
  670. data/lib/fog/network/openstack/requests/create_lbaas_healthmonitor.rb +57 -0
  671. data/lib/fog/network/openstack/requests/create_lbaas_l7policy.rb +50 -0
  672. data/lib/fog/network/openstack/requests/create_lbaas_l7rule.rb +50 -0
  673. data/lib/fog/network/openstack/requests/create_lbaas_listener.rb +55 -0
  674. data/lib/fog/network/openstack/requests/create_lbaas_loadbalancer.rb +52 -0
  675. data/lib/fog/network/openstack/requests/create_lbaas_pool.rb +53 -0
  676. data/lib/fog/network/openstack/requests/create_lbaas_pool_member.rb +49 -0
  677. data/lib/fog/network/openstack/requests/create_network.rb +88 -0
  678. data/lib/fog/network/openstack/requests/create_port.rb +53 -0
  679. data/lib/fog/network/openstack/requests/create_rbac_policy.rb +42 -0
  680. data/lib/fog/network/openstack/requests/create_router.rb +76 -0
  681. data/lib/fog/network/openstack/requests/create_security_group.rb +92 -0
  682. data/lib/fog/network/openstack/requests/create_security_group_rule.rb +79 -0
  683. data/lib/fog/network/openstack/requests/create_subnet.rb +54 -0
  684. data/lib/fog/network/openstack/requests/create_subnet_pool.rb +56 -0
  685. data/lib/fog/network/openstack/requests/create_vpn_service.rb +51 -0
  686. data/lib/fog/network/openstack/requests/delete_floating_ip.rb +28 -0
  687. data/lib/fog/network/openstack/requests/delete_ike_policy.rb +28 -0
  688. data/lib/fog/network/openstack/requests/delete_ipsec_policy.rb +28 -0
  689. data/lib/fog/network/openstack/requests/delete_ipsec_site_connection.rb +29 -0
  690. data/lib/fog/network/openstack/requests/delete_lb_health_monitor.rb +28 -0
  691. data/lib/fog/network/openstack/requests/delete_lb_member.rb +28 -0
  692. data/lib/fog/network/openstack/requests/delete_lb_pool.rb +28 -0
  693. data/lib/fog/network/openstack/requests/delete_lb_vip.rb +28 -0
  694. data/lib/fog/network/openstack/requests/delete_lbaas_healthmonitor.rb +28 -0
  695. data/lib/fog/network/openstack/requests/delete_lbaas_l7policy.rb +28 -0
  696. data/lib/fog/network/openstack/requests/delete_lbaas_l7rule.rb +28 -0
  697. data/lib/fog/network/openstack/requests/delete_lbaas_listener.rb +28 -0
  698. data/lib/fog/network/openstack/requests/delete_lbaas_loadbalancer.rb +28 -0
  699. data/lib/fog/network/openstack/requests/delete_lbaas_pool.rb +28 -0
  700. data/lib/fog/network/openstack/requests/delete_lbaas_pool_member.rb +28 -0
  701. data/lib/fog/network/openstack/requests/delete_network.rb +28 -0
  702. data/lib/fog/network/openstack/requests/delete_port.rb +28 -0
  703. data/lib/fog/network/openstack/requests/delete_quota.rb +23 -0
  704. data/lib/fog/network/openstack/requests/delete_rbac_policy.rb +28 -0
  705. data/lib/fog/network/openstack/requests/delete_router.rb +28 -0
  706. data/lib/fog/network/openstack/requests/delete_security_group.rb +32 -0
  707. data/lib/fog/network/openstack/requests/delete_security_group_rule.rb +32 -0
  708. data/lib/fog/network/openstack/requests/delete_subnet.rb +28 -0
  709. data/lib/fog/network/openstack/requests/delete_subnet_pool.rb +28 -0
  710. data/lib/fog/network/openstack/requests/delete_vpn_service.rb +28 -0
  711. data/lib/fog/network/openstack/requests/disassociate_floating_ip.rb +47 -0
  712. data/lib/fog/network/openstack/requests/disassociate_lb_health_monitor.rb +29 -0
  713. data/lib/fog/network/openstack/requests/get_extension.rb +28 -0
  714. data/lib/fog/network/openstack/requests/get_floating_ip.rb +39 -0
  715. data/lib/fog/network/openstack/requests/get_ike_policy.rb +28 -0
  716. data/lib/fog/network/openstack/requests/get_ipsec_policy.rb +28 -0
  717. data/lib/fog/network/openstack/requests/get_ipsec_site_connection.rb +28 -0
  718. data/lib/fog/network/openstack/requests/get_lb_health_monitor.rb +28 -0
  719. data/lib/fog/network/openstack/requests/get_lb_member.rb +28 -0
  720. data/lib/fog/network/openstack/requests/get_lb_pool.rb +28 -0
  721. data/lib/fog/network/openstack/requests/get_lb_pool_stats.rb +33 -0
  722. data/lib/fog/network/openstack/requests/get_lb_vip.rb +28 -0
  723. data/lib/fog/network/openstack/requests/get_lbaas_healthmonitor.rb +28 -0
  724. data/lib/fog/network/openstack/requests/get_lbaas_l7policy.rb +28 -0
  725. data/lib/fog/network/openstack/requests/get_lbaas_l7rule.rb +28 -0
  726. data/lib/fog/network/openstack/requests/get_lbaas_listener.rb +28 -0
  727. data/lib/fog/network/openstack/requests/get_lbaas_loadbalancer.rb +28 -0
  728. data/lib/fog/network/openstack/requests/get_lbaas_pool.rb +28 -0
  729. data/lib/fog/network/openstack/requests/get_lbaas_pool_member.rb +28 -0
  730. data/lib/fog/network/openstack/requests/get_network.rb +28 -0
  731. data/lib/fog/network/openstack/requests/get_network_ip_availability.rb +28 -0
  732. data/lib/fog/network/openstack/requests/get_port.rb +51 -0
  733. data/lib/fog/network/openstack/requests/get_quota.rb +26 -0
  734. data/lib/fog/network/openstack/requests/get_quotas.rb +26 -0
  735. data/lib/fog/network/openstack/requests/get_rbac_policy.rb +28 -0
  736. data/lib/fog/network/openstack/requests/get_router.rb +30 -0
  737. data/lib/fog/network/openstack/requests/get_security_group.rb +52 -0
  738. data/lib/fog/network/openstack/requests/get_security_group_rule.rb +47 -0
  739. data/lib/fog/network/openstack/requests/get_subnet.rb +47 -0
  740. data/lib/fog/network/openstack/requests/get_subnet_pool.rb +29 -0
  741. data/lib/fog/network/openstack/requests/get_vpn_service.rb +28 -0
  742. data/lib/fog/network/openstack/requests/list_extensions.rb +25 -0
  743. data/lib/fog/network/openstack/requests/list_floating_ips.rb +25 -0
  744. data/lib/fog/network/openstack/requests/list_ike_policies.rb +25 -0
  745. data/lib/fog/network/openstack/requests/list_ipsec_policies.rb +25 -0
  746. data/lib/fog/network/openstack/requests/list_ipsec_site_connections.rb +25 -0
  747. data/lib/fog/network/openstack/requests/list_lb_health_monitors.rb +25 -0
  748. data/lib/fog/network/openstack/requests/list_lb_members.rb +25 -0
  749. data/lib/fog/network/openstack/requests/list_lb_pools.rb +25 -0
  750. data/lib/fog/network/openstack/requests/list_lb_vips.rb +25 -0
  751. data/lib/fog/network/openstack/requests/list_lbaas_healthmonitors.rb +25 -0
  752. data/lib/fog/network/openstack/requests/list_lbaas_l7policies.rb +25 -0
  753. data/lib/fog/network/openstack/requests/list_lbaas_l7rules.rb +25 -0
  754. data/lib/fog/network/openstack/requests/list_lbaas_listeners.rb +25 -0
  755. data/lib/fog/network/openstack/requests/list_lbaas_loadbalancers.rb +25 -0
  756. data/lib/fog/network/openstack/requests/list_lbaas_pool_members.rb +25 -0
  757. data/lib/fog/network/openstack/requests/list_lbaas_pools.rb +25 -0
  758. data/lib/fog/network/openstack/requests/list_network_ip_availabilities.rb +28 -0
  759. data/lib/fog/network/openstack/requests/list_networks.rb +25 -0
  760. data/lib/fog/network/openstack/requests/list_ports.rb +25 -0
  761. data/lib/fog/network/openstack/requests/list_rbac_policies.rb +25 -0
  762. data/lib/fog/network/openstack/requests/list_routers.rb +25 -0
  763. data/lib/fog/network/openstack/requests/list_security_group_rules.rb +48 -0
  764. data/lib/fog/network/openstack/requests/list_security_groups.rb +53 -0
  765. data/lib/fog/network/openstack/requests/list_subnet_pools.rb +25 -0
  766. data/lib/fog/network/openstack/requests/list_subnets.rb +25 -0
  767. data/lib/fog/network/openstack/requests/list_vpn_services.rb +25 -0
  768. data/lib/fog/network/openstack/requests/remove_router_interface.rb +34 -0
  769. data/lib/fog/network/openstack/requests/set_tenant.rb +20 -0
  770. data/lib/fog/network/openstack/requests/update_ike_policy.rb +48 -0
  771. data/lib/fog/network/openstack/requests/update_ipsec_policy.rb +51 -0
  772. data/lib/fog/network/openstack/requests/update_ipsec_site_connection.rb +63 -0
  773. data/lib/fog/network/openstack/requests/update_lb_health_monitor.rb +43 -0
  774. data/lib/fog/network/openstack/requests/update_lb_member.rb +39 -0
  775. data/lib/fog/network/openstack/requests/update_lb_pool.rb +40 -0
  776. data/lib/fog/network/openstack/requests/update_lb_vip.rb +42 -0
  777. data/lib/fog/network/openstack/requests/update_lbaas_healthmonitor.rb +43 -0
  778. data/lib/fog/network/openstack/requests/update_lbaas_l7policy.rb +43 -0
  779. data/lib/fog/network/openstack/requests/update_lbaas_l7rule.rb +42 -0
  780. data/lib/fog/network/openstack/requests/update_lbaas_listener.rb +44 -0
  781. data/lib/fog/network/openstack/requests/update_lbaas_loadbalancer.rb +41 -0
  782. data/lib/fog/network/openstack/requests/update_lbaas_pool.rb +40 -0
  783. data/lib/fog/network/openstack/requests/update_lbaas_pool_member.rb +39 -0
  784. data/lib/fog/network/openstack/requests/update_network.rb +58 -0
  785. data/lib/fog/network/openstack/requests/update_port.rb +44 -0
  786. data/lib/fog/network/openstack/requests/update_quota.rb +27 -0
  787. data/lib/fog/network/openstack/requests/update_rbac_policy.rb +41 -0
  788. data/lib/fog/network/openstack/requests/update_router.rb +71 -0
  789. data/lib/fog/network/openstack/requests/update_security_group.rb +41 -0
  790. data/lib/fog/network/openstack/requests/update_subnet.rb +43 -0
  791. data/lib/fog/network/openstack/requests/update_subnet_pool.rb +46 -0
  792. data/lib/fog/network/openstack/requests/update_vpn_service.rb +46 -0
  793. data/lib/fog/nfv/openstack.rb +133 -0
  794. data/lib/fog/nfv/openstack/models/vnf.rb +58 -0
  795. data/lib/fog/nfv/openstack/models/vnfd.rb +53 -0
  796. data/lib/fog/nfv/openstack/models/vnfds.rb +28 -0
  797. data/lib/fog/nfv/openstack/models/vnfs.rb +28 -0
  798. data/lib/fog/nfv/openstack/requests/create_vnf.rb +37 -0
  799. data/lib/fog/nfv/openstack/requests/create_vnfd.rb +35 -0
  800. data/lib/fog/nfv/openstack/requests/delete_vnf.rb +23 -0
  801. data/lib/fog/nfv/openstack/requests/delete_vnfd.rb +23 -0
  802. data/lib/fog/nfv/openstack/requests/get_vnf.rb +24 -0
  803. data/lib/fog/nfv/openstack/requests/get_vnfd.rb +24 -0
  804. data/lib/fog/nfv/openstack/requests/list_vnfds.rb +25 -0
  805. data/lib/fog/nfv/openstack/requests/list_vnfs.rb +25 -0
  806. data/lib/fog/nfv/openstack/requests/update_vnf.rb +35 -0
  807. data/lib/fog/openstack.rb +622 -0
  808. data/lib/fog/openstack/core.rb +218 -0
  809. data/lib/fog/openstack/errors.rb +42 -0
  810. data/lib/fog/openstack/models/collection.rb +48 -0
  811. data/lib/fog/openstack/models/meta_parent.rb +31 -0
  812. data/lib/fog/openstack/models/model.rb +44 -0
  813. data/lib/fog/openstack/version.rb +5 -0
  814. data/lib/fog/orchestration/openstack.rb +156 -0
  815. data/lib/fog/orchestration/openstack/models/event.rb +18 -0
  816. data/lib/fog/orchestration/openstack/models/events.rb +31 -0
  817. data/lib/fog/orchestration/openstack/models/resource.rb +30 -0
  818. data/lib/fog/orchestration/openstack/models/resource_schemas.rb +15 -0
  819. data/lib/fog/orchestration/openstack/models/resources.rb +35 -0
  820. data/lib/fog/orchestration/openstack/models/stack.rb +128 -0
  821. data/lib/fog/orchestration/openstack/models/stacks.rb +64 -0
  822. data/lib/fog/orchestration/openstack/models/template.rb +13 -0
  823. data/lib/fog/orchestration/openstack/models/templates.rb +45 -0
  824. data/lib/fog/orchestration/openstack/requests/abandon_stack.rb +15 -0
  825. data/lib/fog/orchestration/openstack/requests/build_info.rb +15 -0
  826. data/lib/fog/orchestration/openstack/requests/cancel_update.rb +26 -0
  827. data/lib/fog/orchestration/openstack/requests/create_stack.rb +99 -0
  828. data/lib/fog/orchestration/openstack/requests/delete_stack.rb +58 -0
  829. data/lib/fog/orchestration/openstack/requests/get_stack_template.rb +20 -0
  830. data/lib/fog/orchestration/openstack/requests/list_events.rb +46 -0
  831. data/lib/fog/orchestration/openstack/requests/list_resource_events.rb +28 -0
  832. data/lib/fog/orchestration/openstack/requests/list_resource_types.rb +27 -0
  833. data/lib/fog/orchestration/openstack/requests/list_resources.rb +46 -0
  834. data/lib/fog/orchestration/openstack/requests/list_stack_data.rb +27 -0
  835. data/lib/fog/orchestration/openstack/requests/list_stack_data_detailed.rb +49 -0
  836. data/lib/fog/orchestration/openstack/requests/list_stack_events.rb +27 -0
  837. data/lib/fog/orchestration/openstack/requests/patch_stack.rb +37 -0
  838. data/lib/fog/orchestration/openstack/requests/preview_stack.rb +16 -0
  839. data/lib/fog/orchestration/openstack/requests/show_event_details.rb +26 -0
  840. data/lib/fog/orchestration/openstack/requests/show_resource_data.rb +26 -0
  841. data/lib/fog/orchestration/openstack/requests/show_resource_metadata.rb +26 -0
  842. data/lib/fog/orchestration/openstack/requests/show_resource_schema.rb +15 -0
  843. data/lib/fog/orchestration/openstack/requests/show_resource_template.rb +20 -0
  844. data/lib/fog/orchestration/openstack/requests/show_stack_details.rb +26 -0
  845. data/lib/fog/orchestration/openstack/requests/update_stack.rb +88 -0
  846. data/lib/fog/orchestration/openstack/requests/validate_template.rb +16 -0
  847. data/lib/fog/orchestration/util/recursive_hot_file_loader.rb +220 -0
  848. data/lib/fog/planning/openstack.rb +149 -0
  849. data/lib/fog/planning/openstack/models/plan.rb +69 -0
  850. data/lib/fog/planning/openstack/models/plans.rb +31 -0
  851. data/lib/fog/planning/openstack/models/role.rb +23 -0
  852. data/lib/fog/planning/openstack/models/roles.rb +16 -0
  853. data/lib/fog/planning/openstack/requests/add_role_to_plan.rb +40 -0
  854. data/lib/fog/planning/openstack/requests/create_plan.rb +33 -0
  855. data/lib/fog/planning/openstack/requests/delete_plan.rb +23 -0
  856. data/lib/fog/planning/openstack/requests/get_plan.rb +58 -0
  857. data/lib/fog/planning/openstack/requests/get_plan_templates.rb +28 -0
  858. data/lib/fog/planning/openstack/requests/list_plans.rb +61 -0
  859. data/lib/fog/planning/openstack/requests/list_roles.rb +32 -0
  860. data/lib/fog/planning/openstack/requests/patch_plan.rb +51 -0
  861. data/lib/fog/planning/openstack/requests/remove_role_from_plan.rb +32 -0
  862. data/lib/fog/shared_file_system/openstack.rb +389 -0
  863. data/lib/fog/shared_file_system/openstack/models/availability_zone.rb +15 -0
  864. data/lib/fog/shared_file_system/openstack/models/availability_zones.rb +16 -0
  865. data/lib/fog/shared_file_system/openstack/models/network.rb +42 -0
  866. data/lib/fog/shared_file_system/openstack/models/networks.rb +28 -0
  867. data/lib/fog/shared_file_system/openstack/models/share.rb +95 -0
  868. data/lib/fog/shared_file_system/openstack/models/share_access_rule.rb +35 -0
  869. data/lib/fog/shared_file_system/openstack/models/share_access_rules.rb +30 -0
  870. data/lib/fog/shared_file_system/openstack/models/share_export_location.rb +16 -0
  871. data/lib/fog/shared_file_system/openstack/models/share_export_locations.rb +31 -0
  872. data/lib/fog/shared_file_system/openstack/models/shares.rb +28 -0
  873. data/lib/fog/shared_file_system/openstack/models/snapshot.rb +45 -0
  874. data/lib/fog/shared_file_system/openstack/models/snapshots.rb +28 -0
  875. data/lib/fog/shared_file_system/openstack/requests/add_security_service_to_share_network.rb +28 -0
  876. data/lib/fog/shared_file_system/openstack/requests/create_security_service.rb +47 -0
  877. data/lib/fog/shared_file_system/openstack/requests/create_share.rb +49 -0
  878. data/lib/fog/shared_file_system/openstack/requests/create_share_network.rb +41 -0
  879. data/lib/fog/shared_file_system/openstack/requests/create_snapshot.rb +46 -0
  880. data/lib/fog/shared_file_system/openstack/requests/delete_security_service.rb +24 -0
  881. data/lib/fog/shared_file_system/openstack/requests/delete_share.rb +29 -0
  882. data/lib/fog/shared_file_system/openstack/requests/delete_share_network.rb +28 -0
  883. data/lib/fog/shared_file_system/openstack/requests/delete_snapshot.rb +30 -0
  884. data/lib/fog/shared_file_system/openstack/requests/extend_share.rb +24 -0
  885. data/lib/fog/shared_file_system/openstack/requests/get_limits.rb +45 -0
  886. data/lib/fog/shared_file_system/openstack/requests/get_quota.rb +26 -0
  887. data/lib/fog/shared_file_system/openstack/requests/get_security_service.rb +26 -0
  888. data/lib/fog/shared_file_system/openstack/requests/get_share.rb +26 -0
  889. data/lib/fog/shared_file_system/openstack/requests/get_share_export_location.rb +29 -0
  890. data/lib/fog/shared_file_system/openstack/requests/get_share_network.rb +26 -0
  891. data/lib/fog/shared_file_system/openstack/requests/get_snapshot.rb +26 -0
  892. data/lib/fog/shared_file_system/openstack/requests/grant_share_access.rb +34 -0
  893. data/lib/fog/shared_file_system/openstack/requests/list_availability_zones.rb +24 -0
  894. data/lib/fog/shared_file_system/openstack/requests/list_security_services.rb +25 -0
  895. data/lib/fog/shared_file_system/openstack/requests/list_security_services_detail.rb +25 -0
  896. data/lib/fog/shared_file_system/openstack/requests/list_share_access_rules.rb +29 -0
  897. data/lib/fog/shared_file_system/openstack/requests/list_share_export_locations.rb +27 -0
  898. data/lib/fog/shared_file_system/openstack/requests/list_share_networks.rb +25 -0
  899. data/lib/fog/shared_file_system/openstack/requests/list_share_networks_detail.rb +25 -0
  900. data/lib/fog/shared_file_system/openstack/requests/list_shares.rb +25 -0
  901. data/lib/fog/shared_file_system/openstack/requests/list_shares_detail.rb +25 -0
  902. data/lib/fog/shared_file_system/openstack/requests/list_snapshots.rb +25 -0
  903. data/lib/fog/shared_file_system/openstack/requests/list_snapshots_detail.rb +25 -0
  904. data/lib/fog/shared_file_system/openstack/requests/remove_security_service_from_share_network.rb +28 -0
  905. data/lib/fog/shared_file_system/openstack/requests/revoke_share_access.rb +24 -0
  906. data/lib/fog/shared_file_system/openstack/requests/share_action.rb +16 -0
  907. data/lib/fog/shared_file_system/openstack/requests/share_network_action.rb +16 -0
  908. data/lib/fog/shared_file_system/openstack/requests/shrink_share.rb +24 -0
  909. data/lib/fog/shared_file_system/openstack/requests/update_quota.rb +30 -0
  910. data/lib/fog/shared_file_system/openstack/requests/update_security_service.rb +31 -0
  911. data/lib/fog/shared_file_system/openstack/requests/update_share.rb +39 -0
  912. data/lib/fog/shared_file_system/openstack/requests/update_share_network.rb +31 -0
  913. data/lib/fog/shared_file_system/openstack/requests/update_snapshot.rb +31 -0
  914. data/lib/fog/storage/openstack.rb +177 -0
  915. data/lib/fog/storage/openstack/models/directories.rb +36 -0
  916. data/lib/fog/storage/openstack/models/directory.rb +50 -0
  917. data/lib/fog/storage/openstack/models/file.rb +195 -0
  918. data/lib/fog/storage/openstack/models/files.rb +95 -0
  919. data/lib/fog/storage/openstack/requests/copy_object.rb +23 -0
  920. data/lib/fog/storage/openstack/requests/delete_container.rb +20 -0
  921. data/lib/fog/storage/openstack/requests/delete_multiple_objects.rb +65 -0
  922. data/lib/fog/storage/openstack/requests/delete_object.rb +21 -0
  923. data/lib/fog/storage/openstack/requests/delete_static_large_object.rb +41 -0
  924. data/lib/fog/storage/openstack/requests/get_container.rb +42 -0
  925. data/lib/fog/storage/openstack/requests/get_containers.rb +31 -0
  926. data/lib/fog/storage/openstack/requests/get_object.rb +27 -0
  927. data/lib/fog/storage/openstack/requests/get_object_http_url.rb +21 -0
  928. data/lib/fog/storage/openstack/requests/get_object_https_url.rb +81 -0
  929. data/lib/fog/storage/openstack/requests/head_container.rb +26 -0
  930. data/lib/fog/storage/openstack/requests/head_containers.rb +23 -0
  931. data/lib/fog/storage/openstack/requests/head_object.rb +21 -0
  932. data/lib/fog/storage/openstack/requests/post_object.rb +26 -0
  933. data/lib/fog/storage/openstack/requests/post_set_meta_temp_url_key.rb +33 -0
  934. data/lib/fog/storage/openstack/requests/public_url.rb +34 -0
  935. data/lib/fog/storage/openstack/requests/put_container.rb +24 -0
  936. data/lib/fog/storage/openstack/requests/put_dynamic_obj_manifest.rb +41 -0
  937. data/lib/fog/storage/openstack/requests/put_object.rb +65 -0
  938. data/lib/fog/storage/openstack/requests/put_object_manifest.rb +14 -0
  939. data/lib/fog/storage/openstack/requests/put_static_obj_manifest.rb +55 -0
  940. data/lib/fog/volume/openstack.rb +33 -0
  941. data/lib/fog/volume/openstack/models/availability_zone.rb +10 -0
  942. data/lib/fog/volume/openstack/models/availability_zones.rb +14 -0
  943. data/lib/fog/volume/openstack/models/backup.rb +46 -0
  944. data/lib/fog/volume/openstack/models/backups.rb +26 -0
  945. data/lib/fog/volume/openstack/models/snapshot.rb +38 -0
  946. data/lib/fog/volume/openstack/models/snapshots.rb +26 -0
  947. data/lib/fog/volume/openstack/models/transfer.rb +28 -0
  948. data/lib/fog/volume/openstack/models/transfers.rb +34 -0
  949. data/lib/fog/volume/openstack/models/volume.rb +66 -0
  950. data/lib/fog/volume/openstack/models/volume_type.rb +35 -0
  951. data/lib/fog/volume/openstack/models/volume_types.rb +22 -0
  952. data/lib/fog/volume/openstack/models/volumes.rb +35 -0
  953. data/lib/fog/volume/openstack/requests/accept_transfer.rb +22 -0
  954. data/lib/fog/volume/openstack/requests/action.rb +16 -0
  955. data/lib/fog/volume/openstack/requests/create_backup.rb +49 -0
  956. data/lib/fog/volume/openstack/requests/create_snapshot.rb +18 -0
  957. data/lib/fog/volume/openstack/requests/create_transfer.rb +25 -0
  958. data/lib/fog/volume/openstack/requests/create_volume.rb +23 -0
  959. data/lib/fog/volume/openstack/requests/create_volume_type.rb +41 -0
  960. data/lib/fog/volume/openstack/requests/delete_backup.rb +23 -0
  961. data/lib/fog/volume/openstack/requests/delete_metadata.rb +15 -0
  962. data/lib/fog/volume/openstack/requests/delete_snapshot.rb +23 -0
  963. data/lib/fog/volume/openstack/requests/delete_snapshot_metadata.rb +15 -0
  964. data/lib/fog/volume/openstack/requests/delete_transfer.rb +15 -0
  965. data/lib/fog/volume/openstack/requests/delete_volume.rb +23 -0
  966. data/lib/fog/volume/openstack/requests/delete_volume_type.rb +23 -0
  967. data/lib/fog/volume/openstack/requests/extend_volume.rb +25 -0
  968. data/lib/fog/volume/openstack/requests/get_backup_details.rb +34 -0
  969. data/lib/fog/volume/openstack/requests/get_quota.rb +26 -0
  970. data/lib/fog/volume/openstack/requests/get_quota_defaults.rb +26 -0
  971. data/lib/fog/volume/openstack/requests/get_quota_usage.rb +43 -0
  972. data/lib/fog/volume/openstack/requests/get_snapshot_details.rb +15 -0
  973. data/lib/fog/volume/openstack/requests/get_transfer_details.rb +17 -0
  974. data/lib/fog/volume/openstack/requests/get_volume_details.rb +15 -0
  975. data/lib/fog/volume/openstack/requests/get_volume_type_details.rb +32 -0
  976. data/lib/fog/volume/openstack/requests/list_backups.rb +16 -0
  977. data/lib/fog/volume/openstack/requests/list_backups_detailed.rb +45 -0
  978. data/lib/fog/volume/openstack/requests/list_snapshots.rb +41 -0
  979. data/lib/fog/volume/openstack/requests/list_snapshots_detailed.rb +27 -0
  980. data/lib/fog/volume/openstack/requests/list_transfers.rb +18 -0
  981. data/lib/fog/volume/openstack/requests/list_transfers_detailed.rb +18 -0
  982. data/lib/fog/volume/openstack/requests/list_volume_types.rb +41 -0
  983. data/lib/fog/volume/openstack/requests/list_volumes.rb +30 -0
  984. data/lib/fog/volume/openstack/requests/list_volumes_detailed.rb +16 -0
  985. data/lib/fog/volume/openstack/requests/list_zones.rb +32 -0
  986. data/lib/fog/volume/openstack/requests/replace_metadata.rb +20 -0
  987. data/lib/fog/volume/openstack/requests/restore_backup.rb +17 -0
  988. data/lib/fog/volume/openstack/requests/set_tenant.rb +19 -0
  989. data/lib/fog/volume/openstack/requests/snapshot_action.rb +16 -0
  990. data/lib/fog/volume/openstack/requests/update_metadata.rb +20 -0
  991. data/lib/fog/volume/openstack/requests/update_quota.rb +27 -0
  992. data/lib/fog/volume/openstack/requests/update_snapshot.rb +37 -0
  993. data/lib/fog/volume/openstack/requests/update_snapshot_metadata.rb +20 -0
  994. data/lib/fog/volume/openstack/requests/update_volume.rb +25 -0
  995. data/lib/fog/volume/openstack/requests/update_volume_type.rb +41 -0
  996. data/lib/fog/volume/openstack/v1.rb +183 -0
  997. data/lib/fog/volume/openstack/v1/models/availability_zone.rb +15 -0
  998. data/lib/fog/volume/openstack/v1/models/availability_zones.rb +16 -0
  999. data/lib/fog/volume/openstack/v1/models/backup.rb +15 -0
  1000. data/lib/fog/volume/openstack/v1/models/backups.rb +16 -0
  1001. data/lib/fog/volume/openstack/v1/models/snapshot.rb +44 -0
  1002. data/lib/fog/volume/openstack/v1/models/snapshots.rb +16 -0
  1003. data/lib/fog/volume/openstack/v1/models/transfer.rb +18 -0
  1004. data/lib/fog/volume/openstack/v1/models/transfers.rb +16 -0
  1005. data/lib/fog/volume/openstack/v1/models/volume.rb +37 -0
  1006. data/lib/fog/volume/openstack/v1/models/volume_type.rb +16 -0
  1007. data/lib/fog/volume/openstack/v1/models/volume_types.rb +16 -0
  1008. data/lib/fog/volume/openstack/v1/models/volumes.rb +16 -0
  1009. data/lib/fog/volume/openstack/v1/requests/accept_transfer.rb +2 -0
  1010. data/lib/fog/volume/openstack/v1/requests/action.rb +2 -0
  1011. data/lib/fog/volume/openstack/v1/requests/create_backup.rb +2 -0
  1012. data/lib/fog/volume/openstack/v1/requests/create_snapshot.rb +45 -0
  1013. data/lib/fog/volume/openstack/v1/requests/create_transfer.rb +2 -0
  1014. data/lib/fog/volume/openstack/v1/requests/create_volume.rb +49 -0
  1015. data/lib/fog/volume/openstack/v1/requests/create_volume_type.rb +2 -0
  1016. data/lib/fog/volume/openstack/v1/requests/delete_backup.rb +2 -0
  1017. data/lib/fog/volume/openstack/v1/requests/delete_metadata.rb +2 -0
  1018. data/lib/fog/volume/openstack/v1/requests/delete_snapshot.rb +2 -0
  1019. data/lib/fog/volume/openstack/v1/requests/delete_snapshot_metadata.rb +2 -0
  1020. data/lib/fog/volume/openstack/v1/requests/delete_transfer.rb +2 -0
  1021. data/lib/fog/volume/openstack/v1/requests/delete_volume.rb +2 -0
  1022. data/lib/fog/volume/openstack/v1/requests/delete_volume_type.rb +2 -0
  1023. data/lib/fog/volume/openstack/v1/requests/extend_volume.rb +2 -0
  1024. data/lib/fog/volume/openstack/v1/requests/get_backup_details.rb +2 -0
  1025. data/lib/fog/volume/openstack/v1/requests/get_quota.rb +2 -0
  1026. data/lib/fog/volume/openstack/v1/requests/get_quota_defaults.rb +2 -0
  1027. data/lib/fog/volume/openstack/v1/requests/get_quota_usage.rb +2 -0
  1028. data/lib/fog/volume/openstack/v1/requests/get_snapshot_details.rb +32 -0
  1029. data/lib/fog/volume/openstack/v1/requests/get_transfer_details.rb +2 -0
  1030. data/lib/fog/volume/openstack/v1/requests/get_volume_details.rb +35 -0
  1031. data/lib/fog/volume/openstack/v1/requests/get_volume_type_details.rb +2 -0
  1032. data/lib/fog/volume/openstack/v1/requests/list_backups.rb +2 -0
  1033. data/lib/fog/volume/openstack/v1/requests/list_backups_detailed.rb +2 -0
  1034. data/lib/fog/volume/openstack/v1/requests/list_snapshots.rb +2 -0
  1035. data/lib/fog/volume/openstack/v1/requests/list_snapshots_detailed.rb +2 -0
  1036. data/lib/fog/volume/openstack/v1/requests/list_transfers.rb +2 -0
  1037. data/lib/fog/volume/openstack/v1/requests/list_transfers_detailed.rb +2 -0
  1038. data/lib/fog/volume/openstack/v1/requests/list_volume_types.rb +2 -0
  1039. data/lib/fog/volume/openstack/v1/requests/list_volumes.rb +46 -0
  1040. data/lib/fog/volume/openstack/v1/requests/list_volumes_detailed.rb +46 -0
  1041. data/lib/fog/volume/openstack/v1/requests/list_zones.rb +2 -0
  1042. data/lib/fog/volume/openstack/v1/requests/real.rb +11 -0
  1043. data/lib/fog/volume/openstack/v1/requests/real_mock.rb +14 -0
  1044. data/lib/fog/volume/openstack/v1/requests/replace_metadata.rb +2 -0
  1045. data/lib/fog/volume/openstack/v1/requests/restore_backup.rb +2 -0
  1046. data/lib/fog/volume/openstack/v1/requests/set_tenant.rb +2 -0
  1047. data/lib/fog/volume/openstack/v1/requests/update_metadata.rb +2 -0
  1048. data/lib/fog/volume/openstack/v1/requests/update_quota.rb +2 -0
  1049. data/lib/fog/volume/openstack/v1/requests/update_snapshot.rb +2 -0
  1050. data/lib/fog/volume/openstack/v1/requests/update_snapshot_metadata.rb +2 -0
  1051. data/lib/fog/volume/openstack/v1/requests/update_volume.rb +2 -0
  1052. data/lib/fog/volume/openstack/v2.rb +185 -0
  1053. data/lib/fog/volume/openstack/v2/models/availability_zone.rb +15 -0
  1054. data/lib/fog/volume/openstack/v2/models/availability_zones.rb +16 -0
  1055. data/lib/fog/volume/openstack/v2/models/backup.rb +15 -0
  1056. data/lib/fog/volume/openstack/v2/models/backups.rb +16 -0
  1057. data/lib/fog/volume/openstack/v2/models/snapshot.rb +44 -0
  1058. data/lib/fog/volume/openstack/v2/models/snapshots.rb +16 -0
  1059. data/lib/fog/volume/openstack/v2/models/transfer.rb +18 -0
  1060. data/lib/fog/volume/openstack/v2/models/transfers.rb +16 -0
  1061. data/lib/fog/volume/openstack/v2/models/volume.rb +37 -0
  1062. data/lib/fog/volume/openstack/v2/models/volume_type.rb +16 -0
  1063. data/lib/fog/volume/openstack/v2/models/volume_types.rb +16 -0
  1064. data/lib/fog/volume/openstack/v2/models/volumes.rb +16 -0
  1065. data/lib/fog/volume/openstack/v2/requests/accept_transfer.rb +2 -0
  1066. data/lib/fog/volume/openstack/v2/requests/action.rb +2 -0
  1067. data/lib/fog/volume/openstack/v2/requests/create_backup.rb +2 -0
  1068. data/lib/fog/volume/openstack/v2/requests/create_snapshot.rb +45 -0
  1069. data/lib/fog/volume/openstack/v2/requests/create_transfer.rb +2 -0
  1070. data/lib/fog/volume/openstack/v2/requests/create_volume.rb +49 -0
  1071. data/lib/fog/volume/openstack/v2/requests/create_volume_type.rb +2 -0
  1072. data/lib/fog/volume/openstack/v2/requests/delete_backup.rb +2 -0
  1073. data/lib/fog/volume/openstack/v2/requests/delete_metadata.rb +2 -0
  1074. data/lib/fog/volume/openstack/v2/requests/delete_snapshot.rb +2 -0
  1075. data/lib/fog/volume/openstack/v2/requests/delete_snapshot_metadata.rb +2 -0
  1076. data/lib/fog/volume/openstack/v2/requests/delete_transfer.rb +2 -0
  1077. data/lib/fog/volume/openstack/v2/requests/delete_volume.rb +2 -0
  1078. data/lib/fog/volume/openstack/v2/requests/delete_volume_type.rb +2 -0
  1079. data/lib/fog/volume/openstack/v2/requests/extend_volume.rb +2 -0
  1080. data/lib/fog/volume/openstack/v2/requests/get_backup_details.rb +2 -0
  1081. data/lib/fog/volume/openstack/v2/requests/get_quota.rb +2 -0
  1082. data/lib/fog/volume/openstack/v2/requests/get_quota_defaults.rb +2 -0
  1083. data/lib/fog/volume/openstack/v2/requests/get_quota_usage.rb +2 -0
  1084. data/lib/fog/volume/openstack/v2/requests/get_snapshot_details.rb +32 -0
  1085. data/lib/fog/volume/openstack/v2/requests/get_transfer_details.rb +2 -0
  1086. data/lib/fog/volume/openstack/v2/requests/get_volume_details.rb +35 -0
  1087. data/lib/fog/volume/openstack/v2/requests/get_volume_type_details.rb +2 -0
  1088. data/lib/fog/volume/openstack/v2/requests/list_backups.rb +2 -0
  1089. data/lib/fog/volume/openstack/v2/requests/list_backups_detailed.rb +2 -0
  1090. data/lib/fog/volume/openstack/v2/requests/list_snapshots.rb +2 -0
  1091. data/lib/fog/volume/openstack/v2/requests/list_snapshots_detailed.rb +2 -0
  1092. data/lib/fog/volume/openstack/v2/requests/list_transfers.rb +2 -0
  1093. data/lib/fog/volume/openstack/v2/requests/list_transfers_detailed.rb +2 -0
  1094. data/lib/fog/volume/openstack/v2/requests/list_volume_types.rb +2 -0
  1095. data/lib/fog/volume/openstack/v2/requests/list_volumes.rb +46 -0
  1096. data/lib/fog/volume/openstack/v2/requests/list_volumes_detailed.rb +46 -0
  1097. data/lib/fog/volume/openstack/v2/requests/list_zones.rb +2 -0
  1098. data/lib/fog/volume/openstack/v2/requests/real.rb +11 -0
  1099. data/lib/fog/volume/openstack/v2/requests/real_mock.rb +14 -0
  1100. data/lib/fog/volume/openstack/v2/requests/replace_metadata.rb +2 -0
  1101. data/lib/fog/volume/openstack/v2/requests/restore_backup.rb +2 -0
  1102. data/lib/fog/volume/openstack/v2/requests/set_tenant.rb +2 -0
  1103. data/lib/fog/volume/openstack/v2/requests/snapshot_action.rb +2 -0
  1104. data/lib/fog/volume/openstack/v2/requests/update_metadata.rb +2 -0
  1105. data/lib/fog/volume/openstack/v2/requests/update_quota.rb +2 -0
  1106. data/lib/fog/volume/openstack/v2/requests/update_snapshot.rb +2 -0
  1107. data/lib/fog/volume/openstack/v2/requests/update_snapshot_metadata.rb +2 -0
  1108. data/lib/fog/volume/openstack/v2/requests/update_volume.rb +2 -0
  1109. data/lib/fog/volume/openstack/v2/requests/update_volume_type.rb +2 -0
  1110. data/lib/fog/workflow/openstack.rb +12 -0
  1111. data/lib/fog/workflow/openstack/v2.rb +160 -0
  1112. data/lib/fog/workflow/openstack/v2/requests/create_action.rb +28 -0
  1113. data/lib/fog/workflow/openstack/v2/requests/create_action_execution.rb +31 -0
  1114. data/lib/fog/workflow/openstack/v2/requests/create_cron_trigger.rb +55 -0
  1115. data/lib/fog/workflow/openstack/v2/requests/create_environment.rb +31 -0
  1116. data/lib/fog/workflow/openstack/v2/requests/create_execution.rb +30 -0
  1117. data/lib/fog/workflow/openstack/v2/requests/create_workbook.rb +28 -0
  1118. data/lib/fog/workflow/openstack/v2/requests/create_workflow.rb +28 -0
  1119. data/lib/fog/workflow/openstack/v2/requests/delete_action.rb +25 -0
  1120. data/lib/fog/workflow/openstack/v2/requests/delete_action_execution.rb +25 -0
  1121. data/lib/fog/workflow/openstack/v2/requests/delete_cron_trigger.rb +25 -0
  1122. data/lib/fog/workflow/openstack/v2/requests/delete_environment.rb +25 -0
  1123. data/lib/fog/workflow/openstack/v2/requests/delete_execution.rb +25 -0
  1124. data/lib/fog/workflow/openstack/v2/requests/delete_workbook.rb +25 -0
  1125. data/lib/fog/workflow/openstack/v2/requests/delete_workflow.rb +25 -0
  1126. data/lib/fog/workflow/openstack/v2/requests/get_action.rb +27 -0
  1127. data/lib/fog/workflow/openstack/v2/requests/get_action_execution.rb +26 -0
  1128. data/lib/fog/workflow/openstack/v2/requests/get_cron_trigger.rb +28 -0
  1129. data/lib/fog/workflow/openstack/v2/requests/get_environment.rb +28 -0
  1130. data/lib/fog/workflow/openstack/v2/requests/get_execution.rb +26 -0
  1131. data/lib/fog/workflow/openstack/v2/requests/get_task.rb +27 -0
  1132. data/lib/fog/workflow/openstack/v2/requests/get_workbook.rb +28 -0
  1133. data/lib/fog/workflow/openstack/v2/requests/get_workflow.rb +28 -0
  1134. data/lib/fog/workflow/openstack/v2/requests/list_action_executions.rb +28 -0
  1135. data/lib/fog/workflow/openstack/v2/requests/list_actions.rb +30 -0
  1136. data/lib/fog/workflow/openstack/v2/requests/list_cron_triggers.rb +28 -0
  1137. data/lib/fog/workflow/openstack/v2/requests/list_environments.rb +28 -0
  1138. data/lib/fog/workflow/openstack/v2/requests/list_executions.rb +28 -0
  1139. data/lib/fog/workflow/openstack/v2/requests/list_services.rb +28 -0
  1140. data/lib/fog/workflow/openstack/v2/requests/list_tasks.rb +28 -0
  1141. data/lib/fog/workflow/openstack/v2/requests/list_workbooks.rb +28 -0
  1142. data/lib/fog/workflow/openstack/v2/requests/list_workflows.rb +30 -0
  1143. data/lib/fog/workflow/openstack/v2/requests/rerun_task.rb +33 -0
  1144. data/lib/fog/workflow/openstack/v2/requests/update_action.rb +28 -0
  1145. data/lib/fog/workflow/openstack/v2/requests/update_action_execution.rb +33 -0
  1146. data/lib/fog/workflow/openstack/v2/requests/update_environment.rb +31 -0
  1147. data/lib/fog/workflow/openstack/v2/requests/update_execution.rb +33 -0
  1148. data/lib/fog/workflow/openstack/v2/requests/update_workbook.rb +28 -0
  1149. data/lib/fog/workflow/openstack/v2/requests/update_workflow.rb +28 -0
  1150. data/lib/fog/workflow/openstack/v2/requests/validate_action.rb +28 -0
  1151. data/lib/fog/workflow/openstack/v2/requests/validate_workbook.rb +28 -0
  1152. data/lib/fog/workflow/openstack/v2/requests/validate_workflow.rb +28 -0
  1153. data/playbooks/.gitkeep +0 -0
  1154. data/playbooks/fog-openstack-unittest-spec/run.yaml +57 -0
  1155. data/playbooks/fog-openstack-unittest-test/run.yaml +57 -0
  1156. data/supported.md +56 -0
  1157. metadata +1381 -0
@@ -0,0 +1,28 @@
1
+ require 'fog/openstack/models/collection'
2
+ require 'fog/nfv/openstack/models/vnf'
3
+
4
+ module Fog
5
+ module NFV
6
+ class OpenStack
7
+ class Vnfs < Fog::OpenStack::Collection
8
+ model Fog::NFV::OpenStack::Vnf
9
+
10
+ def all(options = {})
11
+ load_response(service.list_vnfs(options), 'vnfs')
12
+ end
13
+
14
+ def get(uuid)
15
+ data = service.get_vnf(uuid).body['vnf']
16
+ new(data)
17
+ rescue Fog::NFV::OpenStack::NotFound
18
+ nil
19
+ end
20
+
21
+ def destroy(uuid)
22
+ vnf = get(uuid)
23
+ vnf.destroy
24
+ end
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,37 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def create_vnf(options)
6
+ options_valid = [
7
+ :auth,
8
+ :vnf,
9
+ ]
10
+
11
+ # Filter only allowed creation attributes
12
+ data = options.select do |key, _|
13
+ options_valid.include?(key.to_sym) || options_valid.include?(key.to_s)
14
+ end
15
+
16
+ request(
17
+ :body => Fog::JSON.encode(data),
18
+ :expects => 201,
19
+ :method => "POST",
20
+ :path => "vnfs"
21
+ )
22
+ end
23
+ end
24
+
25
+ class Mock
26
+ def create_vnf(_)
27
+ response = Excon::Response.new
28
+ response.status = 201
29
+
30
+ create_data = data[:vnfs].first.merge("vnfd_id" => "id")
31
+ response.body = {"vnf" => create_data}
32
+ response
33
+ end
34
+ end
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,35 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def create_vnfd(options)
6
+ options_valid = [
7
+ :auth,
8
+ :vnfd,
9
+ ]
10
+
11
+ # Filter only allowed creation attributes
12
+ data = options.select do |key, _|
13
+ options_valid.include?(key.to_sym) || options_valid.include?(key.to_s)
14
+ end
15
+
16
+ request(
17
+ :body => Fog::JSON.encode(data),
18
+ :expects => 201,
19
+ :method => "POST",
20
+ :path => "vnfds"
21
+ )
22
+ end
23
+ end
24
+
25
+ class Mock
26
+ def create_vnfd(_)
27
+ response = Excon::Response.new
28
+ response.status = 201
29
+ response.body = {"vnfd" => data[:vnfds].first}
30
+ response
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,23 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def delete_vnf(vnf_id)
6
+ request(
7
+ :expects => 204,
8
+ :method => "DELETE",
9
+ :path => "vnfs/#{vnf_id}"
10
+ )
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def delete_vnf(_vnf_id)
16
+ response = Excon::Response.new
17
+ response.status = 204
18
+ response
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,23 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def delete_vnfd(vnfd_id)
6
+ request(
7
+ :expects => 204,
8
+ :method => "DELETE",
9
+ :path => "vnfds/#{vnfd_id}"
10
+ )
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def delete_vnfd(_vnfd_id)
16
+ response = Excon::Response.new
17
+ response.status = 204
18
+ response
19
+ end
20
+ end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,24 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def get_vnf(vnf_id)
6
+ request(
7
+ :expects => 200,
8
+ :method => 'GET',
9
+ :path => "vnfs/#{vnf_id}"
10
+ )
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def get_vnf(_vnf_id)
16
+ response = Excon::Response.new
17
+ response.status = 200
18
+ response.body = {"vnf" => data[:vnfs].first}
19
+ response
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,24 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def get_vnfd(vnfd_id)
6
+ request(
7
+ :expects => 200,
8
+ :method => 'GET',
9
+ :path => "vnfds/#{vnfd_id}"
10
+ )
11
+ end
12
+ end
13
+
14
+ class Mock
15
+ def get_vnfd(_vnfd_id)
16
+ response = Excon::Response.new
17
+ response.status = 200
18
+ response.body = {"vnfd" => data[:vnfds].first}
19
+ response
20
+ end
21
+ end
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,25 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def list_vnfds(options = {})
6
+ request(
7
+ :expects => 200,
8
+ :method => 'GET',
9
+ :path => "vnfds",
10
+ :query => options
11
+ )
12
+ end
13
+ end
14
+
15
+ class Mock
16
+ def list_vnfds(_options = {})
17
+ response = Excon::Response.new
18
+ response.status = 200
19
+ response.body = {"vnfds" => data[:vnfds]}
20
+ response
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,25 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def list_vnfs(options = {})
6
+ request(
7
+ :expects => 200,
8
+ :method => 'GET',
9
+ :path => "vnfs",
10
+ :query => options
11
+ )
12
+ end
13
+ end
14
+
15
+ class Mock
16
+ def list_vnfs(_options = {})
17
+ response = Excon::Response.new
18
+ response.status = 200
19
+ response.body = {"vnfs" => data[:vnfs]}
20
+ response
21
+ end
22
+ end
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,35 @@
1
+ module Fog
2
+ module NFV
3
+ class OpenStack
4
+ class Real
5
+ def update_vnf(id, options)
6
+ options_valid = [
7
+ :auth,
8
+ :vnf,
9
+ ]
10
+
11
+ # Filter only allowed creation attributes
12
+ data = options.select do |key, _|
13
+ options_valid.include?(key.to_sym) || options_valid.include?(key.to_s)
14
+ end
15
+
16
+ request(
17
+ :body => Fog::JSON.encode(data),
18
+ :expects => 200,
19
+ :method => "PUT",
20
+ :path => "vnfs/#{id}"
21
+ )
22
+ end
23
+ end
24
+
25
+ class Mock
26
+ def update_vnf(_, _)
27
+ response = Excon::Response.new
28
+ response.status = 200
29
+ response.body = {"vnf" => data[:vnfs].first}
30
+ response
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,622 @@
1
+ require 'fog/core'
2
+ require 'fog/json'
3
+
4
+ module Fog
5
+ module Baremetal
6
+ autoload :OpenStack, 'fog/baremetal/openstack'
7
+ end
8
+
9
+ module Compute
10
+ autoload :OpenStack, 'fog/compute/openstack'
11
+ end
12
+
13
+ module ContainerInfra
14
+ autoload :OpenStack, 'fog/container_infra/openstack'
15
+ end
16
+
17
+ module DNS
18
+ autoload :OpenStack, 'fog/dns/openstack'
19
+ end
20
+
21
+ module Event
22
+ autoload :OpenStack, 'fog/event/openstack'
23
+ end
24
+
25
+ module Identity
26
+ autoload :OpenStack, 'fog/identity/openstack'
27
+ end
28
+
29
+ module Image
30
+ autoload :OpenStack, 'fog/image/openstack'
31
+ end
32
+
33
+ module Introspection
34
+ autoload :OpenStack, 'fog/introspection/openstack'
35
+ end
36
+
37
+ module KeyManager
38
+ autoload :OpenStack, 'fog/key_manager/openstack'
39
+ end
40
+
41
+ module Metering
42
+ autoload :OpenStack, 'fog/metering/openstack'
43
+ end
44
+
45
+ module Metric
46
+ autoload :OpenStack, 'fog/metric/openstack'
47
+ end
48
+
49
+ module Monitoring
50
+ autoload :OpenStack, 'fog/monitoring/openstack'
51
+ end
52
+
53
+ module Network
54
+ autoload :OpenStack, 'fog/network/openstack'
55
+ end
56
+
57
+ module NFV
58
+ autoload :OpenStack, 'fog/nfv/openstack'
59
+ end
60
+
61
+ module Orchestration
62
+ autoload :OpenStack, 'fog/orchestration/openstack'
63
+ autoload :Util, 'fog/orchestration/util/recursive_hot_file_loader'
64
+ end
65
+
66
+ module SharedFileSystem
67
+ autoload :OpenStack, 'fog/shared_file_system/openstack'
68
+ end
69
+
70
+ module Storage
71
+ autoload :OpenStack, 'fog/storage/openstack'
72
+ end
73
+
74
+ module Volume
75
+ autoload :OpenStack, 'fog/volume/openstack'
76
+ end
77
+
78
+ module Workflow
79
+ autoload :OpenStack, 'fog/workflow/openstack'
80
+
81
+ class OpenStack
82
+ autoload :V2, 'fog/workflow/openstack/v2'
83
+ end
84
+ end
85
+
86
+ module OpenStack
87
+ autoload :VERSION, 'fog/openstack/version'
88
+
89
+ autoload :Core, 'fog/openstack/core'
90
+ autoload :Errors, 'fog/openstack/errors'
91
+ autoload :Planning, 'fog/planning/openstack'
92
+
93
+ extend Fog::Provider
94
+
95
+ service(:baremetal, 'Baremetal')
96
+ service(:compute, 'Compute')
97
+ service(:container_infra, 'ContainerInfra')
98
+ service(:dns, 'DNS')
99
+ service(:event, 'Event')
100
+ service(:identity, 'Identity')
101
+ service(:image, 'Image')
102
+ service(:introspection, 'Introspection')
103
+ service(:key, 'KeyManager')
104
+ service(:metering, 'Metering')
105
+ service(:metric, 'Metric')
106
+ service(:monitoring, 'Monitoring')
107
+ service(:network, 'Network')
108
+ service(:nfv, 'NFV')
109
+ service(:orchestration, 'Orchestration')
110
+ service(:planning, 'Planning')
111
+ service(:shared_file_system, 'SharedFileSystem')
112
+ service(:storage, 'Storage')
113
+ service(:volume, 'Volume')
114
+ service(:workflow, 'Workflow')
115
+
116
+ @token_cache = {}
117
+
118
+ class << self
119
+ attr_accessor :token_cache
120
+ end
121
+
122
+ def self.clear_token_cache
123
+ Fog::OpenStack.token_cache = {}
124
+ end
125
+
126
+ def self.authenticate(options, connection_options = {})
127
+ case options[:openstack_auth_uri].path
128
+ when /v1(\.\d+)?/
129
+ authenticate_v1(options, connection_options)
130
+ when /v2(\.\d+)?/
131
+ authenticate_v2(options, connection_options)
132
+ when /v3(\.\d+)?/
133
+ authenticate_v3(options, connection_options)
134
+ else
135
+ authenticate_v2(options, connection_options)
136
+ end
137
+ end
138
+
139
+ # legacy v1.0 style auth
140
+ def self.authenticate_v1(options, connection_options = {})
141
+ uri = options[:openstack_auth_uri]
142
+ connection = Fog::Core::Connection.new(uri.to_s, false, connection_options)
143
+ @openstack_api_key = options[:openstack_api_key]
144
+ @openstack_username = options[:openstack_username]
145
+
146
+ response = connection.request({
147
+ :expects => [200, 204],
148
+ :headers => {
149
+ 'X-Auth-Key' => @openstack_api_key,
150
+ 'X-Auth-User' => @openstack_username
151
+ },
152
+ :method => 'GET',
153
+ :path => (uri.path and not uri.path.empty?) ? uri.path : 'v1.0'
154
+ })
155
+
156
+ return {
157
+ :token => response.headers['X-Auth-Token'],
158
+ :server_management_url => response.headers['X-Server-Management-Url'] || response.headers['X-Storage-Url'],
159
+ :identity_public_endpoint => response.headers['X-Keystone']
160
+ }
161
+ end
162
+
163
+ # Keystone Style Auth
164
+ def self.authenticate_v2(options, connection_options = {})
165
+ uri = options[:openstack_auth_uri]
166
+ tenant_name = options[:openstack_tenant]
167
+ service_type = options[:openstack_service_type]
168
+ service_name = options[:openstack_service_name]
169
+ identity_service_type = options[:openstack_identity_service_type]
170
+ endpoint_type = (options[:openstack_endpoint_type] || 'publicURL').to_s
171
+ openstack_region = options[:openstack_region]
172
+
173
+ body = retrieve_tokens_v2(options, connection_options)
174
+ service = get_service(body, service_type, service_name)
175
+
176
+ options[:unscoped_token] = body['access']['token']['id']
177
+
178
+ unless service
179
+ unless tenant_name
180
+ response = Fog::Core::Connection.new(
181
+ "#{uri.scheme}://#{uri.host}:#{uri.port}/v2.0/tenants", false, connection_options).request({
182
+ :expects => [200, 204],
183
+ :headers => {'Content-Type' => 'application/json',
184
+ 'Accept' => 'application/json',
185
+ 'X-Auth-Token' => body['access']['token']['id']},
186
+ :method => 'GET'
187
+ })
188
+
189
+ body = Fog::JSON.decode(response.body)
190
+ if body['tenants'].empty?
191
+ raise Fog::Errors::NotFound.new('No Tenant Found')
192
+ else
193
+ options[:openstack_tenant] = body['tenants'].first['name']
194
+ end
195
+ end
196
+
197
+ body = retrieve_tokens_v2(options, connection_options)
198
+ service = get_service(body, service_type, service_name)
199
+
200
+ end
201
+
202
+ unless service
203
+ available = body['access']['serviceCatalog'].map { |endpoint|
204
+ endpoint['type']
205
+ }.sort.join ', '
206
+
207
+ missing = service_type.join ', '
208
+
209
+ message = "Could not find service #{missing}. Have #{available}"
210
+
211
+ raise Fog::Errors::NotFound, message
212
+ end
213
+
214
+ service['endpoints'] = service['endpoints'].select do |endpoint|
215
+ endpoint['region'] == openstack_region
216
+ end if openstack_region
217
+
218
+ if service['endpoints'].empty?
219
+ raise Fog::Errors::NotFound.new("No endpoints available for region '#{openstack_region}'")
220
+ end if openstack_region
221
+
222
+ regions = service["endpoints"].map{ |e| e['region'] }.uniq
223
+ if regions.count > 1
224
+ raise Fog::Errors::NotFound.new("Multiple regions available choose one of these '#{regions.join(',')}'")
225
+ end
226
+
227
+ identity_service = get_service(body, identity_service_type) if identity_service_type
228
+ tenant = body['access']['token']['tenant']
229
+ user = body['access']['user']
230
+
231
+ management_url = service['endpoints'].find{|s| s[endpoint_type]}[endpoint_type]
232
+ identity_url = identity_service['endpoints'].find{|s| s['publicURL']}['publicURL'] if identity_service
233
+
234
+ {
235
+ :user => user,
236
+ :tenant => tenant,
237
+ :identity_public_endpoint => identity_url,
238
+ :server_management_url => management_url,
239
+ :token => body['access']['token']['id'],
240
+ :expires => body['access']['token']['expires'],
241
+ :current_user_id => body['access']['user']['id'],
242
+ :unscoped_token => options[:unscoped_token]
243
+ }
244
+ end
245
+
246
+ # Keystone Style Auth
247
+ def self.authenticate_v3(options, connection_options = {})
248
+ uri = options[:openstack_auth_uri]
249
+ project_name = options[:openstack_project_name]
250
+ service_type = options[:openstack_service_type]
251
+ service_name = options[:openstack_service_name]
252
+ identity_service_type = options[:openstack_identity_service_type]
253
+ endpoint_type = map_endpoint_type(options[:openstack_endpoint_type] || 'publicURL')
254
+ openstack_region = options[:openstack_region]
255
+
256
+ token, body = retrieve_tokens_v3 options, connection_options
257
+
258
+ service = get_service_v3(body, service_type, service_name, openstack_region, options)
259
+
260
+ options[:unscoped_token] = token
261
+
262
+ unless service
263
+ unless project_name
264
+ request_body = {
265
+ :expects => [200],
266
+ :headers => {'Content-Type' => 'application/json',
267
+ 'Accept' => 'application/json',
268
+ 'X-Auth-Token' => token},
269
+ :method => 'GET'
270
+ }
271
+ user_id = body['token']['user']['id']
272
+ project_uri = uri.clone
273
+ project_uri.path = uri.path.sub('/auth/tokens', "/users/#{user_id}/projects")
274
+ project_uri_param = "#{project_uri.scheme}://#{project_uri.host}:#{project_uri.port}#{project_uri.path}"
275
+ response = Fog::Core::Connection.new(project_uri_param, false, connection_options).request(request_body)
276
+
277
+ projects_body = Fog::JSON.decode(response.body)
278
+ if projects_body['projects'].empty?
279
+ options[:openstack_domain_id] = body['token']['user']['domain']['id']
280
+ else
281
+ options[:openstack_project_id] = projects_body['projects'].first['id']
282
+ options[:openstack_project_name] = projects_body['projects'].first['name']
283
+ options[:openstack_domain_id] = projects_body['projects'].first['domain_id']
284
+ end
285
+ end
286
+
287
+ token, body = retrieve_tokens_v3(options, connection_options)
288
+ service = get_service_v3(body, service_type, service_name, openstack_region, options)
289
+ end
290
+
291
+ # If no identity endpoint is found, try the auth uri (slicing /auth/tokens)
292
+ # It covers the case where identityv3 endpoint is not present in the catalog but we have to use it
293
+ unless service
294
+ if service_type.include? "identity"
295
+ identity_uri = uri.to_s.sub('/auth/tokens', '')
296
+ response = Fog::Core::Connection.new(identity_uri, false, connection_options).request({:method => 'GET'})
297
+ if response.status == 200
298
+ service = {
299
+ "endpoints" => [{
300
+ "url" => identity_uri,
301
+ "region" => openstack_region,
302
+ "interface" => endpoint_type
303
+ }],
304
+ "type" => service_type,
305
+ "name" => service_name
306
+ }
307
+ end
308
+ end
309
+ end
310
+
311
+ unless service
312
+ available_services = body['token']['catalog'].map { |service|
313
+ service['type']
314
+ }.sort.join ', '
315
+
316
+ available_regions = body['token']['catalog'].map { |service|
317
+ service['endpoints'].map { |endpoint|
318
+ endpoint['region']
319
+ }.uniq
320
+ }.uniq.sort.join ', '
321
+
322
+ missing = service_type.join ', '
323
+
324
+ message = "Could not find service #{missing}#{(' in region '+openstack_region) if openstack_region}."+
325
+ " Have #{available_services}#{(' in regions '+available_regions) if openstack_region}"
326
+
327
+ raise Fog::Errors::NotFound, message
328
+ end
329
+
330
+ service['endpoints'] = service['endpoints'].select do |endpoint|
331
+ endpoint['region'] == openstack_region && endpoint['interface'] == endpoint_type
332
+ end if openstack_region
333
+
334
+ if service['endpoints'].empty?
335
+ raise Fog::Errors::NotFound.new("No endpoints available for region '#{openstack_region}'")
336
+ end if openstack_region
337
+
338
+ regions = service["endpoints"].map { |e| e['region'] }.uniq
339
+ if regions.count > 1
340
+ raise Fog::Errors::NotFound.new("Multiple regions available choose one of these '#{regions.join(',')}'")
341
+ end
342
+
343
+ identity_service = get_service_v3(body, identity_service_type, nil, nil, :openstack_endpoint_path_matches => /\/v3/) if identity_service_type
344
+
345
+ management_url = service['endpoints'].find { |e| e['interface']==endpoint_type }['url']
346
+ identity_url = identity_service['endpoints'].find { |e| e['interface']=='public' }['url'] if identity_service
347
+
348
+ if body['token']['project']
349
+ tenant = body['token']['project']
350
+ elsif body['token']['user']['project']
351
+ tenant = body['token']['user']['project']
352
+ end
353
+
354
+ return {
355
+ :user => body['token']['user']['name'],
356
+ :tenant => tenant,
357
+ :identity_public_endpoint => identity_url,
358
+ :server_management_url => management_url,
359
+ :token => token,
360
+ :expires => body['token']['expires_at'],
361
+ :current_user_id => body['token']['user']['id'],
362
+ :unscoped_token => options[:unscoped_token]
363
+ }
364
+ end
365
+
366
+ def self.get_service(body, service_type=[], service_name=nil)
367
+ if not body['access'].nil?
368
+ body['access']['serviceCatalog'].find do |s|
369
+ if service_name.nil? or service_name.empty?
370
+ service_type.include?(s['type'])
371
+ else
372
+ service_type.include?(s['type']) and s['name'] == service_name
373
+ end
374
+ end
375
+ elsif not body['token']['catalog'].nil?
376
+ body['token']['catalog'].find do |s|
377
+ if service_name.nil? or service_name.empty?
378
+ service_type.include?(s['type'])
379
+ else
380
+ service_type.include?(s['type']) and s['name'] == service_name
381
+ end
382
+ end
383
+
384
+ end
385
+ end
386
+
387
+ def self.retrieve_tokens_v2(options, connection_options = {})
388
+ api_key = options[:openstack_api_key].to_s
389
+ username = options[:openstack_username].to_s
390
+ tenant_name = options[:openstack_tenant].to_s
391
+ auth_token = options[:openstack_auth_token] || options[:unscoped_token]
392
+ uri = options[:openstack_auth_uri]
393
+ omit_default_port = options[:openstack_auth_omit_default_port]
394
+
395
+ identity_v2_connection = Fog::Core::Connection.new(uri.to_s, false, connection_options)
396
+ request_body = {:auth => Hash.new}
397
+
398
+ if auth_token
399
+ request_body[:auth][:token] = {
400
+ :id => auth_token
401
+ }
402
+ else
403
+ request_body[:auth][:passwordCredentials] = {
404
+ :username => username,
405
+ :password => api_key
406
+ }
407
+ end
408
+ request_body[:auth][:tenantName] = tenant_name if tenant_name
409
+
410
+ request = {
411
+ :expects => [200, 204],
412
+ :headers => {'Content-Type' => 'application/json'},
413
+ :body => Fog::JSON.encode(request_body),
414
+ :method => 'POST',
415
+ :path => (uri.path and not uri.path.empty?) ? uri.path : 'v2.0'
416
+ }
417
+ request[:omit_default_port] = omit_default_port unless omit_default_port.nil?
418
+
419
+ response = identity_v2_connection.request(request)
420
+
421
+ Fog::JSON.decode(response.body)
422
+ end
423
+
424
+ def self.retrieve_tokens_v3(options, connection_options = {})
425
+
426
+ api_key = options[:openstack_api_key].to_s
427
+ username = options[:openstack_username].to_s
428
+ userid = options[:openstack_userid]
429
+ domain_id = options[:openstack_domain_id]
430
+ domain_name = options[:openstack_domain_name]
431
+ project_domain = options[:openstack_project_domain]
432
+ project_domain_id = options[:openstack_project_domain_id]
433
+ user_domain = options[:openstack_user_domain]
434
+ user_domain_id = options[:openstack_user_domain_id]
435
+ project_name = options[:openstack_project_name]
436
+ project_id = options[:openstack_project_id]
437
+ auth_token = options[:openstack_auth_token] || options[:unscoped_token]
438
+ uri = options[:openstack_auth_uri]
439
+ omit_default_port = options[:openstack_auth_omit_default_port]
440
+ cache_ttl = options[:openstack_cache_ttl] || 0
441
+
442
+ connection = Fog::Core::Connection.new(uri.to_s, false, connection_options)
443
+ request_body = {:auth => {}}
444
+
445
+ scope = {}
446
+
447
+ if project_name || project_id
448
+ scope[:project] = if project_id.nil? then
449
+ if project_domain || project_domain_id
450
+ {:name => project_name, :domain => project_domain_id.nil? ? {:name => project_domain} : {:id => project_domain_id}}
451
+ else
452
+ {:name => project_name, :domain => domain_id.nil? ? {:name => domain_name} : {:id => domain_id}}
453
+ end
454
+ else
455
+ {:id => project_id}
456
+ end
457
+ elsif domain_name || domain_id
458
+ scope[:domain] = domain_id.nil? ? {:name => domain_name} : {:id => domain_id}
459
+ else
460
+ # unscoped token
461
+ end
462
+
463
+ if auth_token
464
+ request_body[:auth][:identity] = {
465
+ :methods => %w{token},
466
+ :token => {
467
+ :id => auth_token
468
+ }
469
+ }
470
+ else
471
+ request_body[:auth][:identity] = {
472
+ :methods => %w{password},
473
+ :password => {
474
+ :user => {
475
+ :password => api_key
476
+ }
477
+ }
478
+ }
479
+
480
+ if userid
481
+ request_body[:auth][:identity][:password][:user][:id] = userid
482
+ else
483
+ if user_domain || user_domain_id
484
+ request_body[:auth][:identity][:password][:user].merge! :domain => user_domain_id.nil? ? {:name => user_domain} : {:id => user_domain_id}
485
+ elsif domain_name || domain_id
486
+ request_body[:auth][:identity][:password][:user].merge! :domain => domain_id.nil? ? {:name => domain_name} : {:id => domain_id}
487
+ end
488
+ request_body[:auth][:identity][:password][:user][:name] = username
489
+ end
490
+
491
+ end
492
+ request_body[:auth][:scope] = scope unless scope.empty?
493
+
494
+ path = (uri.path and not uri.path.empty?) ? uri.path : 'v3'
495
+
496
+ response, expires = Fog::OpenStack.token_cache[{:body => request_body, :path => path}] if cache_ttl > 0
497
+
498
+ unless response && expires > Time.now
499
+ request = {
500
+ :expects => [201],
501
+ :headers => {'Content-Type' => 'application/json'},
502
+ :body => Fog::JSON.encode(request_body),
503
+ :method => 'POST',
504
+ :path => path
505
+ }
506
+ request[:omit_default_port] = omit_default_port unless omit_default_port.nil?
507
+
508
+ response = connection.request(request)
509
+ if cache_ttl > 0
510
+ cache = Fog::OpenStack.token_cache
511
+ cache[{:body => request_body, :path => path}] = response, Time.now + cache_ttl
512
+ Fog::OpenStack.token_cache = cache
513
+ end
514
+ end
515
+
516
+ [response.headers["X-Subject-Token"], Fog::JSON.decode(response.body)]
517
+ end
518
+
519
+ def self.get_service_v3(hash, service_type=[], service_name=nil, region=nil, options={})
520
+
521
+ # Find all services matching any of the types in service_type, filtered by service_name if it's non-nil
522
+ services = hash['token']['catalog'].find_all do |s|
523
+ if service_name.nil? or service_name.empty?
524
+ service_type.include?(s['type'])
525
+ else
526
+ service_type.include?(s['type']) and s['name'] == service_name
527
+ end
528
+ end if hash['token']['catalog']
529
+
530
+ # Filter the found services by region (if specified) and whether the endpoint path matches the given regex (e.g. /\/v3/)
531
+ services.find do |s|
532
+ s['endpoints'].any? { |ep| endpoint_region?(ep, region) && endpoint_path_match?(ep, options[:openstack_endpoint_path_matches])}
533
+ end if services
534
+
535
+ end
536
+
537
+ def self.endpoint_region?(endpoint, region)
538
+ region.nil? || endpoint['region'] == region
539
+ end
540
+
541
+ def self.endpoint_path_match?(endpoint, match_regex)
542
+ match_regex.nil? || URI(endpoint['url']).path =~ match_regex
543
+ end
544
+
545
+ def self.get_supported_version(supported_versions, uri, auth_token, connection_options = {})
546
+ supported_version = get_version(supported_versions, uri, auth_token, connection_options)
547
+ version = supported_version['id'] if supported_version
548
+ version_raise(supported_versions) if version.nil?
549
+
550
+ version
551
+ end
552
+
553
+ def self.get_supported_version_path(supported_versions, uri, auth_token, connection_options = {})
554
+ supported_version = get_version(supported_versions, uri, auth_token, connection_options)
555
+ link = supported_version['links'].find { |l| l['rel'] == 'self' } if supported_version
556
+ path = URI.parse(link['href']).path if link
557
+ version_raise(supported_versions) if path.nil?
558
+
559
+ path.chomp '/'
560
+ end
561
+
562
+ def self.get_supported_microversion(supported_versions, uri, auth_token, connection_options = {})
563
+ supported_version = get_version(supported_versions, uri, auth_token, connection_options)
564
+ supported_version['version'] if supported_version
565
+ end
566
+
567
+ # CGI.escape, but without special treatment on spaces
568
+ def self.escape(str, extra_exclude_chars = '')
569
+ str.gsub(/([^a-zA-Z0-9_.-#{extra_exclude_chars}]+)/) do
570
+ '%' + $1.unpack('H2' * $1.bytesize).join('%').upcase
571
+ end
572
+ end
573
+
574
+ def self.map_endpoint_type type
575
+ case type
576
+ when "publicURL"
577
+ "public"
578
+ when "internalURL"
579
+ "internal"
580
+ when "adminURL"
581
+ "admin"
582
+ end
583
+
584
+ end
585
+
586
+ def self.get_version(supported_versions, uri, auth_token, connection_options = {})
587
+ version_cache = "#{uri}#{supported_versions}"
588
+ return @version[version_cache] if @version && @version[version_cache]
589
+ connection = Fog::Core::Connection.new("#{uri.scheme}://#{uri.host}:#{uri.port}", false, connection_options)
590
+ response = connection.request(
591
+ :expects => [200, 204, 300],
592
+ :headers => {'Content-Type' => 'application/json',
593
+ 'Accept' => 'application/json',
594
+ 'X-Auth-Token' => auth_token},
595
+ :method => 'GET'
596
+ )
597
+
598
+ body = Fog::JSON.decode(response.body)
599
+
600
+ @version = {} unless @version
601
+ @version[version_cache] = extract_version_from_body(body, supported_versions)
602
+ end
603
+
604
+ def self.extract_version_from_body(body, supported_versions)
605
+ return nil if body['versions'].empty?
606
+ versions = body['versions'].kind_of?(Array) ? body['versions'] : body['versions']['values']
607
+ version = nil
608
+ # order is important, preffered status should be first
609
+ %w(CURRENT stable SUPPORTED DEPRECATED).each do |status|
610
+ version = versions.find { |x| x['id'].match(supported_versions) && (x['status'] == status) }
611
+ break if version
612
+ end
613
+
614
+ version
615
+ end
616
+
617
+ def self.version_raise(supported_versions)
618
+ raise Fog::OpenStack::Errors::ServiceUnavailable,
619
+ "OpenStack service only supports API versions #{supported_versions.inspect}"
620
+ end
621
+ end
622
+ end