Skip to content

Latest commit

 

History

History
1170 lines (603 loc) · 26 KB

cloud_datastore_module.rst

File metadata and controls

1170 lines (603 loc) · 26 KB
orphan:

morpheus.core.cloud_datastore module -- Configure Cloud Datastores

Note

This module is part of the morpheus.core collection (version 0.7.1).

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install morpheus.core.

To use it in a playbook, specify: morpheus.core.cloud_datastore.

.. rst-class:: ansible-version-added

New in morpheus.core 0.7.0

  • Update the configuration of Cloud Datastores.
.. tabularcolumns:: \X{1}{3}\X{2}{3}

Parameter Comments
.. rst-class:: ansible-option-title

id

.. ansible-option-type-line::

  :ansible-option-type:`integer` / :ansible-option-required:`required`

The Id of the Datastore.

.. rst-class:: ansible-option-title

resource_permissions

.. ansible-option-type-line::

  :ansible-option-type:`dictionary`

Resource permissions for the Datastore.

.. rst-class:: ansible-option-title

all_groups

.. ansible-option-type-line::

  :ansible-option-type:`boolean`

Allow or disallow access to all groups.

.. rst-class:: ansible-option-line

:ansible-option-choices:`Choices:`

.. rst-class:: ansible-option-title

all_plans

.. ansible-option-type-line::

  :ansible-option-type:`boolean`

.. rst-class:: ansible-option-title

groups

.. ansible-option-type-line::

  :ansible-option-aliases:`aliases: sites`

  :ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary`

List of groups that are allowed access to the Datastore.

.. rst-class:: ansible-option-title

group_id

.. ansible-option-type-line::

  :ansible-option-aliases:`aliases: site_id`

  :ansible-option-type:`integer`

Id of the group to allow access.

.. rst-class:: ansible-option-title

state

.. ansible-option-type-line::

  :ansible-option-type:`string`

.. rst-class:: ansible-option-title

plans

.. ansible-option-type-line::

  :ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary`

List of Plans to allow access.

.. rst-class:: ansible-option-title

plan_id

.. ansible-option-type-line::

  :ansible-option-type:`integer`

Id of the Plan to allow access.

.. rst-class:: ansible-option-title

state

.. ansible-option-type-line::

  :ansible-option-type:`string`

.. rst-class:: ansible-option-title

state

.. ansible-option-type-line::

  :ansible-option-type:`string`

.. rst-class:: ansible-option-title

tenant_permissions

.. ansible-option-type-line::

  :ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary`

List of Tenant Permissions on the Datastore.

.. rst-class:: ansible-option-title

default_store

.. ansible-option-type-line::

  :ansible-option-type:`boolean`

Set the Datastore as the default image store for the specified tenant.

.. rst-class:: ansible-option-line

:ansible-option-choices:`Choices:`

.. rst-class:: ansible-option-title

default_target

.. ansible-option-type-line::

  :ansible-option-type:`boolean`

Set the Datastore as the default for the specified tenant.

.. rst-class:: ansible-option-line

:ansible-option-choices:`Choices:`

.. rst-class:: ansible-option-title

state

.. ansible-option-type-line::

  :ansible-option-type:`string`

.. rst-class:: ansible-option-title

tenant_id

.. ansible-option-type-line::

  :ansible-option-type:`integer` / :ansible-option-required:`required`

The id of the tenant to add or remove permissions for.

.. rst-class:: ansible-option-title

visibility

.. ansible-option-type-line::

  :ansible-option-type:`string`

.. rst-class:: ansible-option-title

zone_id

.. ansible-option-type-line::

  :ansible-option-aliases:`aliases: cloud_id`

  :ansible-option-type:`integer` / :ansible-option-required:`required`

The Id of the Cloud the Datastore belongs to.

.. tabularcolumns:: \X{2}{10}\X{3}{10}\X{5}{10}

Attribute Support Description
.. rst-class:: ansible-option-title

check_mode

Can run in check_mode and return changed status prediction without modifying target

.. rst-class:: ansible-option-title

diff_mode

Will return details on what has changed (or possibly needs changing in check_mode), when in diff mode

.. rst-class:: ansible-option-title

platform

Target OS/families that can be operated against

- name: Set a Datastore to Active and Public Visibility
  morpheus.core.cloud_datastore:
    id: 30
    cloud_id: 5
    state: active
    visibility: public

- name: Configure Tenant Access to Datastore
  morpheus.core.cloud_datastore:
    id: 30
    cloud_id: 5
    tenant_permissions:
        - state: present
          tenant_id: 50
          default_target: true
        - state: present
          tenant_id: 51
          default_target: true
          default_store: true
        - state: absent
          tenant_id: 2

- name: Configure Group Access and Allow all Price Plans
  morpheus.core.cloud_datastore:
    id: 35
    cloud_id: 6
    resource_permissions:
        groups:
            - state: present
              group_id: 7
        all_plans: true

Common return values are documented :ref:`here <common_return_values>`, the following are the fields unique to this module:

.. tabularcolumns:: \X{1}{3}\X{2}{3}

Key Description
.. rst-class:: ansible-option-title

datastore

.. ansible-option-type-line::

  :ansible-option-type:`dictionary`

Authors

  • James Riach (@McGlovin1337)

Collection links

.. ansible-links::

  - title: "Repository (Sources)"
    url: "https://www.github.com/gomorpheus/ansible-collection-morpheus-core"
    external: true