Skip to content

Instantly share code, notes, and snippets.

@funkytaco
Created October 7, 2022 19:51
Show Gist options
  • Save funkytaco/6c597be7bb5725919f2efb262aec7aad to your computer and use it in GitHub Desktop.
Save funkytaco/6c597be7bb5725919f2efb262aec7aad to your computer and use it in GitHub Desktop.
purestorage.flasharray examples
To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install purestorage.flasharray.
To use it in a playbook, specify: purestorage.flasharray.purefa_volume.
name: Create new volume named foo with a QoS limit
purefa_volume:
name: foo
size: 1T
bw_qos: 58M
iops_qos: 23K
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Create new volume named foo in pod bar in protection group pg1
purefa_volume:
name: bar::foo
prgoup: pg1
size: 1T
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Create 10 volumes with index starting at 10 but padded with 3 digits
purefa_volume:
name: foo
size: 1T
suffix: bar
count: 10
start: 10
digits: 3
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Extend the size of an existing volume named foo
purefa_volume:
name: foo
size: 2T
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Delete and eradicate volume named foo
purefa_volume:
name: foo
eradicate: yes
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: absent
- name: Create clone of volume bar named foo
purefa_volume:
name: foo
target: bar
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Overwrite volume bar with volume foo
purefa_volume:
name: foo
target: bar
overwrite: yes
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Clear volume QoS from volume foo
purefa_volume:
name: foo
bw_qos: 0
iops_qos: 0
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
state: present
- name: Move local volume foo from local array to pod bar
purefa_volume:
name: foo
move: bar
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
- name: Move volume foo in pod bar to local array
purefa_volume:
name: bar::foo
move: local
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
- name: Move volume foo in pod bar to vgroup fin
purefa_volume:
name: bar::foo
move: fin
fa_url: 10.10.10.2
api_token: e31060a7-21fc-e277-6240-25983c6c4592
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment