ovirt_host: add iscsi portal (#66750)

* ovirt_host: add iscsi portal

* correct version_added to 2.10
This commit is contained in:
Martin Nečas 2020-01-25 14:18:34 +01:00 committed by ansibot
parent f1ec48429a
commit d7a1917c17
2 changed files with 51 additions and 8 deletions

View file

@ -126,7 +126,27 @@ options:
used to discover targets"
- "If C(state) is I(iscsilogin) it means that the iscsi attribute is being
used to login to the specified targets passed as part of the iscsi attribute"
version_added: "2.4"
suboptions:
username:
description:
- "A CHAP user name for logging into a target."
password:
description:
- "A CHAP password for logging into a target."
address:
description:
- "Address of the iSCSI storage server."
target:
description:
- "The target IQN for the storage device."
port:
description:
- "The port being used to connect with iscsi."
portal:
description:
- "The portal being used to connect with iscsi."
version_added: 2.10
version_added: 2.4
check_upgrade:
description:
- "If I(true) and C(state) is I(upgraded) run check for upgrade
@ -581,6 +601,7 @@ def main():
username=iscsi_param.get('username'),
password=iscsi_param.get('password'),
address=iscsi_param.get('address'),
portal=iscsi_param.get('portal'),
),
)
ret = {
@ -599,6 +620,7 @@ def main():
password=iscsi_param.get('password'),
address=iscsi_param.get('address'),
target=iscsi_param.get('target'),
portal=iscsi_param.get('portal'),
),
)
elif state == 'started':

View file

@ -26,16 +26,36 @@ options:
iscsi:
description:
- "Dictionary with values for iSCSI storage type:"
- "C(address) - Address of the iSCSI storage server."
- "C(target) - The target IQN for the storage device."
- "C(username) - A CHAP user name for logging into a target."
- "C(password) - A CHAP password for logging into a target."
suboptions:
address:
description:
- "Address of the iSCSI storage server."
target:
description:
- "The target IQN for the storage device."
username:
description:
- "A CHAP user name for logging into a target."
password:
description:
- "A CHAP password for logging into a target."
portal:
description:
- "The portal being used to connect with iscsi."
version_added: 2.10
fcp:
description:
- "Dictionary with values for fibre channel storage type:"
- "C(address) - Address of the fibre channel storage server."
- "C(port) - Port of the fibre channel storage server."
- "C(lun_id) - LUN id."
suboptions:
address:
description:
- "Address of the fibre channel storage server."
port:
description:
- "Port of the fibre channel storage server."
lun_id:
description:
- "LUN id."
extends_documentation_fragment: ovirt_info
'''
@ -86,6 +106,7 @@ def _login(host_service, iscsi):
password=iscsi.get('password'),
address=iscsi.get('address'),
target=iscsi.get('target'),
portal=iscsi.get('portal')
),
)