doc_fragments: Clean up parameter types (storage) (#52179)

* module_utils: Clean up parameter types (storage)

This PR includes:

- Parameter types added
- Copyright format fixes
- Short license statement
- Description fixes (only for a few files, then I stopped :-))

* Fix quotes

* Fix rST issue
pull/52315/head
Dag Wieers 6 years ago committed by John R Barker
parent 6a82827ddd
commit fbca8a4615

@ -1,43 +1,42 @@
# # -*- coding: utf-8 -*-
# Copyright (c) 2018, Luca 'remix_tj' Lorenzetto <lorenzetto.luca@gmail.com>
# # Copyright: (c) 2018, Luca Lorenzetto (@remix_tj) <lorenzetto.luca@gmail.com>
# This file is part of Ansible
#
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
class ModuleDocFragment(object): class ModuleDocFragment(object):
DOCUMENTATION = """ DOCUMENTATION = r'''
options: options:
- See respective platform section for more details - See respective platform section for more details
requirements: requirements:
- See respective platform section for more details - See respective platform section for more details
notes: notes:
- Ansible modules are available for EMC VNX. - Ansible modules are available for EMC VNX.
""" '''
# Documentation fragment for VNX (emc_vnx) # Documentation fragment for VNX (emc_vnx)
EMC_VNX = """ EMC_VNX = r'''
options: options:
sp_address: sp_address:
description: description:
- Address of the SP of target/secondary storage. - Address of the SP of target/secondary storage.
type: str
required: true required: true
sp_user: sp_user:
description: description:
- Username for accessing SP. - Username for accessing SP.
type: str
default: sysadmin default: sysadmin
required: false
sp_password: sp_password:
description: description:
- password for accessing SP. - password for accessing SP.
type: str
default: sysadmin default: sysadmin
required: false
requirements: requirements:
- An EMC VNX Storage device. - An EMC VNX Storage device.
- Ansible 2.7. - Ansible 2.7.
- storops (0.5.10 or greater). Install using 'pip install storops'. - storops (0.5.10 or greater). Install using 'pip install storops'.
notes: notes:
- The modules prefixed with emc_vnx are built to support the EMC VNX storage platform. - The modules prefixed with emc_vnx are built to support the EMC VNX storage platform.
""" '''

@ -1,5 +1,6 @@
# # -*- coding: utf-8 -*-
# Copyright (C) 2018 IBM CORPORATION
# Copyright: (c) 2018, IBM CORPORATION
# Author(s): Tzur Eliyahu <tzure@il.ibm.com> # Author(s): Tzur Eliyahu <tzure@il.ibm.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
@ -10,24 +11,27 @@ __metaclass__ = type
class ModuleDocFragment(object): class ModuleDocFragment(object):
# ibm_storage documentation fragment # ibm_storage documentation fragment
DOCUMENTATION = ''' DOCUMENTATION = r'''
options: options:
username: username:
description: description:
- Management user on the spectrum accelerate storage system. - Management user on the spectrum accelerate storage system.
type: str
required: True required: True
password: password:
description: description:
- Password for username on the spectrum accelerate storage system. - Password for username on the spectrum accelerate storage system.
type: str
required: True required: True
endpoints: endpoints:
description: description:
- The hostname or management IP of Spectrum Accelerate storage system. - The hostname or management IP of Spectrum Accelerate storage system.
type: str
required: True required: True
notes: notes:
- This module requires pyxcli python library. - This module requires pyxcli python library.
Use 'pip install pyxcli' in order to get pyxcli. Use 'pip install pyxcli' in order to get pyxcli.
requirements: requirements:
- "python >= 2.7" - python >= 2.7
- pyxcli - pyxcli
''' '''

@ -1,30 +1,18 @@
# # -*- coding: utf-8 -*-
# (c) 2016, Gregory Shulov <gregory.shulov@gmail.com>
# # Copyright: (c) 2016, Gregory Shulov <gregory.shulov@gmail.com>
# This file is part of Ansible # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
class ModuleDocFragment(object): class ModuleDocFragment(object):
# Standard Infinibox documentation fragment # Standard Infinibox documentation fragment
DOCUMENTATION = ''' DOCUMENTATION = r'''
options: options:
system: system:
description: description:
- Infinibox Hostname or IPv4 Address. - Infinibox Hostname or IPv4 Address.
type: str
required: true required: true
user: user:
description: description:
@ -33,7 +21,7 @@ options:
password: password:
description: description:
- Infinibox User password. - Infinibox User password.
required: false type: str
notes: notes:
- This module requires infinisdk python library - This module requires infinisdk python library
- You must set INFINIBOX_USER and INFINIBOX_PASSWORD environment variables - You must set INFINIBOX_USER and INFINIBOX_PASSWORD environment variables

@ -1,62 +1,52 @@
# # -*- coding: utf-8 -*-
# (c) 2018, Sumit Kumar <sumit4@netapp.com>, chris Archibald <carchi@netapp.com>
# # Copyright: (c) 2018, Sumit Kumar <sumit4@netapp.com>, chris Archibald <carchi@netapp.com>
# This file is part of Ansible # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
class ModuleDocFragment(object): class ModuleDocFragment(object):
DOCUMENTATION = """ DOCUMENTATION = r'''
options: options:
- See respective platform section for more details - See respective platform section for more details
requirements: requirements:
- See respective platform section for more details - See respective platform section for more details
notes: notes:
- Ansible modules are available for the following NetApp Storage Platforms: E-Series, ONTAP, SolidFire - Ansible modules are available for the following NetApp Storage Platforms: E-Series, ONTAP, SolidFire
""" '''
# Documentation fragment for ONTAP (na_ontap) # Documentation fragment for ONTAP (na_ontap)
NA_ONTAP = """ NA_ONTAP = r'''
options: options:
hostname: hostname:
required: true
description: description:
- The hostname or IP address of the ONTAP instance. - The hostname or IP address of the ONTAP instance.
username: type: str
required: true required: true
username:
description: description:
- This can be a Cluster-scoped or SVM-scoped account, depending on whether a Cluster-level or SVM-level API is required. - This can be a Cluster-scoped or SVM-scoped account, depending on whether a Cluster-level or SVM-level API is required.
For more information, please read the documentation U(https://mysupport.netapp.com/NOW/download/software/nmsdk/9.4/). For more information, please read the documentation U(https://mysupport.netapp.com/NOW/download/software/nmsdk/9.4/).
aliases: ['user'] type: str
password:
required: true required: true
aliases: [ user ]
password:
description: description:
- Password for the specified user. - Password for the specified user.
aliases: ['pass'] type: str
required: true
aliases: [ pass ]
https: https:
description: description:
- Enable and disable https - Enable and disable https
type: bool type: bool
default: false default: no
validate_certs: validate_certs:
description: description:
- If set to C(False), the SSL certificates will not be validated. - If set to C(no), the SSL certificates will not be validated.
- This should only set to C(False) used on personally controlled sites using self-signed certificates. - This should only set to C(False) used on personally controlled sites using self-signed certificates.
default: true
type: bool type: bool
default: yes
http_port: http_port:
description: description:
- Override the default port (80 or 443) with this port - Override the default port (80 or 443) with this port
@ -77,10 +67,10 @@ requirements:
notes: notes:
- The modules prefixed with na\\_ontap are built to support the ONTAP storage platform. - The modules prefixed with na\\_ontap are built to support the ONTAP storage platform.
""" '''
# Documentation fragment for ONTAP (na_cdot) # Documentation fragment for ONTAP (na_cdot)
ONTAP = """ ONTAP = r'''
options: options:
hostname: hostname:
required: true required: true
@ -105,10 +95,10 @@ requirements:
notes: notes:
- The modules prefixed with na\\_cdot are built to support the ONTAP storage platform. - The modules prefixed with na\\_cdot are built to support the ONTAP storage platform.
""" '''
# Documentation fragment for SolidFire # Documentation fragment for SolidFire
SOLIDFIRE = """ SOLIDFIRE = r'''
options: options:
hostname: hostname:
required: true required: true
@ -133,10 +123,10 @@ requirements:
notes: notes:
- The modules prefixed with na\\_elementsw are built to support the SolidFire storage platform. - The modules prefixed with na\\_elementsw are built to support the SolidFire storage platform.
""" '''
# Documentation fragment for E-Series # Documentation fragment for E-Series
ESERIES = """ ESERIES = r'''
options: options:
api_username: api_username:
required: true required: true
@ -168,4 +158,4 @@ notes:
the storage-system, or an E-Series storage-system that supports the Embedded Web Services API. the storage-system, or an E-Series storage-system that supports the Embedded Web Services API.
- Embedded Web Services is currently available on the E2800, E5700, EF570, and newer hardware models. - Embedded Web Services is currently available on the E2800, E5700, EF570, and newer hardware models.
- M(netapp_e_storage_system) may be utilized for configuring the systems managed by a WSP instance. - M(netapp_e_storage_system) may be utilized for configuring the systems managed by a WSP instance.
""" '''

@ -1,26 +1,13 @@
# # -*- coding: utf-8 -*-
# (c) 2017, Simon Dodsley <simon@purestorage.com>
# # Copyright: (c) 2017, Simon Dodsley <simon@purestorage.com>
# This file is part of Ansible # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
class ModuleDocFragment(object): class ModuleDocFragment(object):
# Standard Pure Storage documentation fragment # Standard Pure Storage documentation fragment
DOCUMENTATION = ''' DOCUMENTATION = r'''
options: options:
- See separate platform section for more details - See separate platform section for more details
requirements: requirements:
@ -30,39 +17,43 @@ notes:
''' '''
# Documentation fragment for FlashBlade # Documentation fragment for FlashBlade
FB = ''' FB = r'''
options: options:
fb_url: fb_url:
description: description:
- FlashBlade management IP address or Hostname. - FlashBlade management IP address or Hostname.
type: str
api_token: api_token:
description: description:
- FlashBlade API token for admin privileged user. - FlashBlade API token for admin privileged user.
type: str
notes: notes:
- This module requires the ``purity_fb`` Python library - This module requires the C(purity_fb) Python library
- You must set C(PUREFB_URL) and C(PUREFB_API) environment variables - You must set C(PUREFB_URL) and C(PUREFB_API) environment variables
if I(fb_url) and I(api_token) arguments are not passed to the module directly if I(fb_url) and I(api_token) arguments are not passed to the module directly
requirements: requirements:
- "python >= 2.7" - python >= 2.7
- "purity_fb >= 1.1" - purity_fb >= 1.1
''' '''
# Documentation fragment for FlashArray # Documentation fragment for FlashArray
FA = ''' FA = r'''
options: options:
fa_url: fa_url:
description: description:
- FlashArray management IPv4 address or Hostname. - FlashArray management IPv4 address or Hostname.
type: str
required: true required: true
api_token: api_token:
description: description:
- FlashArray API token for admin privileged user. - FlashArray API token for admin privileged user.
type: str
required: true required: true
notes: notes:
- This module requires the ``purestorage`` Python library - This module requires the C(purestorage) Python library
- You must set C(PUREFA_URL) and C(PUREFA_API) environment variables - You must set C(PUREFA_URL) and C(PUREFA_API) environment variables
if I(fa_url) and I(api_token) arguments are not passed to the module directly if I(fa_url) and I(api_token) arguments are not passed to the module directly
requirements: requirements:
- "python >= 2.7" - python >= 2.7
- purestorage - purestorage
''' '''

Loading…
Cancel
Save