dellemc.powerflex.resource_group module – Manage resource group deployments on Dell PowerFlex.

Note

This module is part of the dellemc.powerflex collection (version 2.5.0).

You might already have this collection installed if you are using the ansible package. 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 dellemc.powerflex. You need further requirements to be able to use this module, see Requirements for details.

To use it in a playbook, specify: dellemc.powerflex.resource_group.

New in dellemc.powerflex 2.3.0

Synopsis

  • Managing resource group deployments on PowerFlex storage system includes deploying, editing, adding nodes and deleting a resource group deployment.

Requirements

The below requirements are needed on the host that executes this module.

  • A Dell PowerFlex storage system version 3.6 or later.

  • PyPowerFlex 1.12.0.

Parameters

Parameter

Comments

clone_node

string

Resource to duplicate during scaleup, if more than one nodes are available in the resource group.

description

string

The description of the resource group.

firmware_repository_id

string

The ID of the firmware repository if not using the appliance default catalog.

Mutually exclusive with firmware_repository_name.

firmware_repository_name

string

The name of the firmware repository if not using the appliance default catalog.

Mutually exclusive with firmware_repository_id.

hostname

aliases: gateway_host

string / required

IP or FQDN of the PowerFlex host.

new_resource_group_name

string

New name of the resource group to rename to.

node_count

integer

Number of nodes to clone during scaleup.

Default: 1

password

string / required

The password of the PowerFlex host.

port

integer

Port number through which communication happens with PowerFlex host.

Default: 443

resource_group_id

string

The ID of the resource group.

Either resource_group_id or resource_group_name must be specified to perform resource group operations.

Mutually exclusive with resource_group_name.

resource_group_name

string

The name of the resource group.

This is a required field to deploy a resource group.

Either resource_group_id or resource_group_name must be specified to perform resource group operations.

Mutually exclusive with resource_group_id.

scaleup

boolean

Whether to scale up the resource group. Specify as true to add nodes to the resource group.

Choices:

  • false ← (default)

  • true

schedule_date

string

Scheduled date for the resource group deployment.

Specify in YYYY-MM-DD HH:MM:SS.sss or YYYY-MM-DD format.

state

string

The state of the resource group.

Choices:

  • "absent"

  • "present" ← (default)

template_id

string

The ID of the published template.

Either template_id or template_name must be specified to deploy a resource group.

Mutually exclusive with template_name.

template_name

string

The name of the published template.

Either template_id or template_name must be specified to deploy a resource group.

Mutually exclusive with template_id.

timeout

integer

Time after which connection will get terminated.

It is to be mentioned in seconds.

Default: 120

username

string / required

The username of the PowerFlex host.

validate

boolean

Specify as true to validate the deployment of resource group.

Choices:

  • false ← (default)

  • true

validate_certs

aliases: verifycert

boolean

Boolean variable to specify whether or not to validate SSL certificate.

true - Indicates that the SSL certificate should be verified.

false - Indicates that the SSL certificate should not be verified.

Choices:

  • false

  • true ← (default)

Notes

Note

  • The check_mode is supported.

  • Resource group scale up can be done only when deployment is complete.

  • The modules present in the collection named as ‘dellemc.powerflex’ are built to support the Dell PowerFlex storage platform.

Examples

- name: Validate deployment of a resource group
  dellemc.powerflex.resource_group:
    hostname: "{{ hostname }}"
    username: "{{ username }}"
    password: "{{ password }}"
    validate_certs: "{{ validate_certs }}"
    port: "{{ port }}"
    resource_group_name: "{{ resource_group_name_1 }}"
    description: ans_rg
    template_id: c65d0172-8666-48ab-935e-9a0bf69ed66d
    firmware_repository_id: 8aaa80788b5755d1018b576126d51ba3
    validate: true

- name: Deploy a resource group
  dellemc.powerflex.resource_group:
    hostname: "{{ hostname }}"
    username: "{{ username }}"
    password: "{{ password }}"
    validate_certs: "{{ validate_certs }}"
    port: "{{ port }}"
    resource_group_name: "{{ resource_group_name_1 }}"
    description: ans_rg
    template_id: c65d0172-8666-48ab-935e-9a0bf69ed66d
    firmware_repository_id: 8aaa80788b5755d1018b576126d51ba3

- name: Add a node to a resource group
  dellemc.powerflex.resource_group:
    hostname: "{{ hostname }}"
    username: "{{ username }}"
    password: "{{ password }}"
    validate_certs: "{{ validate_certs }}"
    resource_group_name: "{{ resource_group_name_1 }}"
    scaleup: true
    clone_node: "{{ node_1 }}"
    node_count: "{{ node_count }}"

- name: Modify a resource group
  dellemc.powerflex.resource_group:
    hostname: "{{ hostname }}"
    username: "{{ username }}"
    password: "{{ password }}"
    validate_certs: "{{ validate_certs }}"
    resource_group_name: "{{ resource_group_name_1 }}"
    new_resource_group_name: "{{ new_resource_group_name }}"
    description: "description new"

- name: Delete a resource group
  dellemc.powerflex.resource_group:
    hostname: "{{ hostname }}"
    username: "{{ username }}"
    password: "{{ password }}"
    validate_certs: "{{ validate_certs }}"
    port: "{{ port }}"
    resource_group_name: ans_rg
    state: "absent"

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

changed

boolean

Whether or not the resource has changed.

Returned: always

Sample: false

resource_group_details

dictionary

Details of the resource group deployment.

Returned: When resource group exists.

Sample: {"allUsersAllowed": false, "brownfield": false, "compliant": true, "configurationChange": false, "deploymentDescription": "ans test rg", "deploymentDevice": [{"brownfield": false, "compliantState": "COMPLIANT", "componentId": "910bf934-d45a-4fe3-8ea2-dc481e063a81", "currentIpAddress": "1.3.9.2", "deviceHealth": "GREEN", "deviceType": "scaleio", "model": "PowerFlex Gateway", "refId": "scaleio-block-legacy-gateway", "refType": "SCALEIO", "statusMessage": "The processing of PowerFlex is unsuccessful."}], "deploymentHealthStatusType": "red", "deploymentName": "dep-ans-test-rg1", "firmwareRepository": {"id": "8aaa80788b5755d1018b576126d51ba3", "name": "PowerFlex 4.5.0.0", "rcmapproved": false}, "firmwareRepositoryId": "8aaa80788b5755d1018b576126d51ba3", "id": "8aaa03a88de961fa018de96a88d80008", "lifecycleMode": false, "numberOfDeployments": 0, "owner": "admin", "retry": true, "scaleUp": false, "scheduleDate": null, "serviceTemplate": {"id": "8aaa03a88de961fa018de96a88d80008", "templateName": "update-template (8aaa03a88de961fa018de96a88d80008)"}, "status": "error", "teardown": false, "templateValid": true, "updateServerFirmware": true, "useDefaultCatalog": true, "vds": false}

deploymentDescription

string

The description of the resource group deployment.

Returned: success

deploymentName

string

The name of the resource group deployment.

Returned: success

firmwareRepositoryId

string

The ID of the firmware repository of the resource group.

Returned: success

id

string

The ID of the deployed resource group.

Returned: success

serviceTemplate

dictionary

The service template of the resource group.

Returned: success

id

string

The ID of the service template.

Returned: success

templateName

string

The name of the service template.

Returned: success

status

string

The status of the deployment of the resource group.

Returned: success

Authors

  • Jennifer John (@johnj9)

  • Trisha Datta (@trisha-dell)