ngine_io / ngine_io.cloudstack / 2.3.0 / module / cs_storage_pool Manages Primary Storage Pools on Apache CloudStack based clouds. | "added in version" 0.1.0 of ngine_io.cloudstack" Authors: Netservers Ltd. (@netservers), René Moser (@resmo)ngine_io.cloudstack.cs_storage_pool (2.3.0) — module
Install with ansible-galaxy collection install ngine_io.cloudstack:==2.3.0
collections: - name: ngine_io.cloudstack version: 2.3.0
Create, update, put into maintenance, disable, enable and remove storage pools.
- name: ensure a zone scoped storage_pool is present ngine_io.cloudstack.cs_storage_pool: zone: zone01 storage_url: rbd://admin:SECRET@ceph-mons.domain/poolname provider: DefaultPrimary name: Ceph RBD scope: zone hypervisor: KVM
- name: ensure a cluster scoped storage_pool is disabled ngine_io.cloudstack.cs_storage_pool: name: Ceph RBD zone: zone01 cluster: cluster01 pod: pod01 storage_url: rbd://admin:SECRET@ceph-the-mons.domain/poolname provider: DefaultPrimary scope: cluster allocation_state: disabled
- name: ensure a cluster scoped storage_pool is in maintenance ngine_io.cloudstack.cs_storage_pool: name: Ceph RBD zone: zone01 cluster: cluster01 pod: pod01 storage_url: rbd://admin:SECRET@ceph-the-mons.domain/poolname provider: DefaultPrimary scope: cluster allocation_state: maintenance
- name: ensure a storage_pool is absent ngine_io.cloudstack.cs_storage_pool: name: Ceph RBD zone: zone01 state: absent
pod: description: - Name of the pod. type: str name: description: - Name of the storage pool. required: true type: str zone: description: - Name of the zone in which the host should be deployed. required: true type: str scope: choices: - cluster - zone description: - The scope of the storage pool. - Defaults to cluster when C(cluster) is provided, otherwise zone. type: str state: choices: - present - absent default: present description: - State of the storage pool. type: str api_key: description: - API key of the CloudStack API. - If not given, the C(CLOUDSTACK_KEY) env variable is considered. required: true type: str api_url: description: - URL of the CloudStack API e.g. https://cloud.example.com/client/api. - If not given, the C(CLOUDSTACK_ENDPOINT) env variable is considered. required: true type: str cluster: description: - Name of the cluster. type: str managed: description: - Whether the storage pool should be managed by CloudStack. - Only considered on creation. type: bool provider: default: DefaultPrimary description: - Name of the storage provider e.g. SolidFire, SolidFireShared, DefaultPrimary, CloudByte. type: str api_secret: description: - Secret key of the CloudStack API. - If not set, the C(CLOUDSTACK_SECRET) env variable is considered. required: true type: str hypervisor: description: - Required when creating a zone scoped pool. - Possible values are C(KVM), C(VMware), C(BareMetal), C(XenServer), C(LXC), C(HyperV), C(UCS), C(OVM), C(Simulator). type: str api_timeout: default: 10 description: - HTTP timeout in seconds. - If not given, the C(CLOUDSTACK_TIMEOUT) env variable is considered. type: int storage_url: description: - URL of the storage pool. - Required if I(state=present). type: str storage_tags: aliases: - storage_tag description: - Tags associated with this storage pool. elements: str type: list capacity_iops: description: - Bytes CloudStack can provision from this storage pool. type: int capacity_bytes: description: - Bytes CloudStack can provision from this storage pool. type: int api_http_method: choices: - get - post default: get description: - HTTP method used to query the API endpoint. - If not given, the C(CLOUDSTACK_METHOD) env variable is considered. type: str allocation_state: choices: - enabled - disabled - maintenance description: - Allocation state of the storage pool. type: str api_verify_ssl_cert: description: - Verify CA authority cert file. - If not given, the C(CLOUDSTACK_VERIFY) env variable is considered. type: str
allocation_state: description: The state of the storage pool. returned: success sample: enabled type: str capacity_iops: description: IOPS CloudStack can provision from this storage pool returned: when available sample: 60000 type: int cluster: description: The name of the cluster. returned: when scope is cluster sample: Cluster01 type: str created: description: Date of the pool was created. returned: success sample: 2014-12-01T14:57:57+0100 type: str disk_size_allocated: description: The pool's currently allocated disk space. returned: success sample: 2443517624320 type: int disk_size_total: description: The total size of the pool. returned: success sample: 3915055693824 type: int disk_size_used: description: The pool's currently used disk size. returned: success sample: 1040862622180 type: int hypervisor: description: Hypervisor related to this storage pool. returned: when available sample: KVM type: str id: description: UUID of the pool. returned: success sample: a3fca65a-7db1-4891-b97c-48806a978a96 type: str overprovision_factor: description: The overprovision factor of the storage pool. returned: success sample: 2.0 type: str path: description: The storage pool path used in the storage_url. returned: success sample: poolname type: str pod: description: The name of the pod. returned: when scope is cluster sample: Cluster01 type: str scope: description: The scope of the storage pool. returned: success sample: cluster type: str state: description: The state of the storage pool as returned by the API. returned: success sample: Up type: str storage_capabilities: description: Capabilities of the storage pool. returned: success sample: VOLUME_SNAPSHOT_QUIESCEVM: 'false' type: dict storage_tags: description: the tags for the storage pool. returned: success sample: - perf - ssd type: list suitable_for_migration: description: Whether the storage pool is suitable to migrate a volume or not. returned: success sample: false type: bool zone: description: The name of the zone. returned: success sample: Zone01 type: str