os_mapping.rst 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. Detailed OpenStack Type and Resource Mappings
  2. =============================================
  3. OpenStack - Labeled Resources
  4. -----------------------------
  5. +------------------------+------------------------+-----------+----------------+----------+
  6. | Labeled Resource | OS Resource Type | CB ID | CB Name | CB Label |
  7. +========================+========================+===========+================+==========+
  8. | OpenStackInstance | Instance | ID | ID | Name |
  9. +------------------------+------------------------+-----------+----------------+----------+
  10. | OpenStackMachineImage | Image | ID | ID | Name |
  11. +------------------------+------------------------+-----------+----------------+----------+
  12. | OpenStackNetwork | Network | ID | ID | Name |
  13. +------------------------+------------------------+-----------+----------------+----------+
  14. | OpenStackSubnet | Subnet | ID | ID | Name |
  15. +------------------------+------------------------+-----------+----------------+----------+
  16. | OpenStackRouter | Router | ID | ID | Name |
  17. +------------------------+------------------------+-----------+----------------+----------+
  18. | OpenStackVolume | Volume | ID | ID | Name |
  19. +------------------------+------------------------+-----------+----------------+----------+
  20. | OpenStackSnapshot | Snapshot | ID | ID | Name |
  21. +------------------------+------------------------+-----------+----------------+----------+
  22. | OpenStackVMFirewall | Security Group | ID | ID | Name |
  23. +------------------------+------------------------+-----------+----------------+----------+
  24. The resources listed above are labeled, they thus have both the `name` and
  25. `label` properties in CloudBridge. These resources require a mandatory `label`
  26. parameter at creation. For all labeled resources, the `label` property in
  27. OpenStack maps to the Name attribute. However, unlike in Azure or AWS, no
  28. resource has an unchangeable name by which to identify it in our OpenStack
  29. implementation. The `name` property will therefore map to the ID, preserving
  30. its role as an unchangeable identifier even though not easily readable in this
  31. context. Finally, labeled resources support a `label` parameter for the `find`
  32. method in their corresponding services. The below screenshots will help map
  33. these properties to OpenStack objects in the web portal. Additionally, although
  34. OpenStack Security Groups are not associated with a specific network, such an
  35. association is done in CloudBridge, due to its necessity in AWS. As such, the
  36. VMFirewall creation method requires a `network` parameter and the association
  37. is accomplished in OpenStack through the description, by appending the
  38. following string to the user-provided description (if any) at creation:
  39. "[CB-AUTO-associated-network-id: associated_net_id]"
  40. .. figure:: captures/os-instance-dash.png
  41. :alt: name, ID, and label properties for OS Instances
  42. The CloudBridge `name` and `ID` properties map to the unchangeable
  43. resource ID in OpenStack as resources do not allow for an unchangeable
  44. name. The `label` property maps to the 'Name' for all resources in
  45. OpenStack. By default, this label will appear in the first column.
  46. OpenStack - Unlabeled Resources
  47. -------------------------------
  48. +-----------------------+------------------------+-------+---------+----------+
  49. | Unlabeled Resource | OS Resource Type | CB ID | CB Name | CB Label |
  50. +=======================+========================+=======+=========+==========+
  51. | OpenStackKeyPair | Key Pair | Name | Name | - |
  52. +-----------------------+------------------------+-------+---------+----------+
  53. | OpenStackBucket | Object Store Container | Name | Name | - |
  54. +-----------------------+------------------------+-------+---------+----------+
  55. | OpenStackBucketObject | Object | Name | Name | - |
  56. +-----------------------+------------------------+-------+---------+----------+
  57. The resources listed above are unlabeled. They thus only have the `name`
  58. property in CloudBridge. These resources require a mandatory `name`
  59. parameter at creation, which will directly map to the unchangeable `name`
  60. property. Additionally, for these resources, the `ID` property also maps to
  61. the `name` in OpenStack, as these resources don't have an `ID` in the
  62. traditional sense and can be identified by name. Finally, unlabeled resources
  63. support a `name` parameter for the `find` method in their corresponding
  64. services.
  65. .. figure:: captures/os-kp-dash.png
  66. :alt: KeyPair details on OS dashboard
  67. KeyPairs and other unlabeled resources in OpenStack have `name` that is
  68. unique and unmodifiable. The `ID` will thus map to the `name` property when
  69. no other `ID` exists for that OpenStack resource.
  70. OpenStack - Special Unlabeled Resources
  71. ---------------------------------------
  72. +--------------------------+------------------------+-------+------------------------------------------------------------------------+----------+
  73. | Unlabeled Resource | OS Resource Type | CB ID | CB Name | CB Label |
  74. +==========================+========================+=======+========================================================================+==========+
  75. | OpenStackFloatingIP | Floating IP | ID | [public_ip] | - |
  76. +--------------------------+------------------------+-------+------------------------------------------------------------------------+----------+
  77. | OpenStackInternetGateway | Network `public` | ID | 'public' | - |
  78. +--------------------------+------------------------+-------+------------------------------------------------------------------------+----------+
  79. | OpenStackVMFirewallRule | Security Group Rule | ID | Generated: [direction]-[protocol]-[from_port]-[to_port]-[cidr]-[fw_id] | - |
  80. +--------------------------+------------------------+-------+------------------------------------------------------------------------+----------+
  81. While these resources are similarly unlabeled, they do not follow the same
  82. general rules as the ones listed before. Firstly, they differ by the fact
  83. that they take neither a `name` nor a `label` parameter at creation.
  84. Moreover, each of them has other special properties.
  85. The FloatingIP resource has a traditional resource ID, but instead of a
  86. traditional name, its `name` property maps to its Public IP.
  87. Moreover, the corresponding `find` method for Floating IPs can thus help
  88. find a resource by `Public IP Address`.
  89. In terms of the gateway in OpenStack, it maps to the network named 'public.'
  90. Thus, the internet gateway create method does not take a name parameter, and
  91. the `name` property will be 'public'.
  92. Finally, Firewall Rules in OpenStack differ from traditional unlabeled resources
  93. by the fact that they do not take a `name` parameter at creation, and the
  94. `name` property is automatically generated from the rule's properties, as
  95. shown above. These rules can be found within each Firewall (i.e. Security
  96. Group) in the web portal, and will not have any name in the OpenStack dashboard.