mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-03 06:49:10 -07:00
lvol: Change `pvs
` argument type to list (of str) (#7676)
* lvol: Change ``pvs`` argument type to list (of str) * Add changelog fragment * Apply review suggestions
This commit is contained in:
parent
3d0da92784
commit
a599afa384
8 changed files with 215 additions and 5 deletions
|
@ -75,9 +75,10 @@ options:
|
|||
description:
|
||||
- The name of a snapshot volume to be configured. When creating a snapshot volume, the O(lv) parameter specifies the origin volume.
|
||||
pvs:
|
||||
type: str
|
||||
type: list
|
||||
elements: str
|
||||
description:
|
||||
- Comma separated list of physical volumes (e.g. /dev/sda,/dev/sdb).
|
||||
- List of physical volumes (for example V(/dev/sda, /dev/sdb)).
|
||||
thinpool:
|
||||
type: str
|
||||
description:
|
||||
|
@ -110,7 +111,9 @@ EXAMPLES = '''
|
|||
vg: firefly
|
||||
lv: test
|
||||
size: 512
|
||||
pvs: /dev/sda,/dev/sdb
|
||||
pvs:
|
||||
- /dev/sda
|
||||
- /dev/sdb
|
||||
|
||||
- name: Create cache pool logical volume
|
||||
community.general.lvol:
|
||||
|
@ -299,7 +302,7 @@ def main():
|
|||
shrink=dict(type='bool', default=True),
|
||||
active=dict(type='bool', default=True),
|
||||
snapshot=dict(type='str'),
|
||||
pvs=dict(type='str'),
|
||||
pvs=dict(type='list', elements='str'),
|
||||
resizefs=dict(type='bool', default=False),
|
||||
thinpool=dict(type='str'),
|
||||
),
|
||||
|
@ -340,7 +343,7 @@ def main():
|
|||
if pvs is None:
|
||||
pvs = ""
|
||||
else:
|
||||
pvs = pvs.replace(",", " ")
|
||||
pvs = " ".join(pvs)
|
||||
|
||||
if opts is None:
|
||||
opts = ""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue