mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 13:52:54 +00:00
Clean up module documentation (#36909)
* Clean up module documentation This PR includes: - Removal of `default: None` (and variations) - Removal of `required: false` - Fixing booleans and `type: bool` where required * Fix remaining (new) validation issues
This commit is contained in:
@@ -27,7 +27,6 @@ options:
|
||||
description:
|
||||
- The hostname of the vcenter server the module will connect to, to create the guest.
|
||||
required: true
|
||||
default: null
|
||||
validate_certs:
|
||||
description:
|
||||
- Validate SSL certs. Note, if running on python without SSLContext
|
||||
@@ -35,9 +34,8 @@ options:
|
||||
as pysphere does not support validating certificates on older python.
|
||||
Prior to 2.1, this module would always validate on python >= 2.7.9 and
|
||||
never validate on python <= 2.7.8.
|
||||
required: false
|
||||
default: yes
|
||||
type: bool
|
||||
default: 'yes'
|
||||
version_added: 2.1
|
||||
guest:
|
||||
description:
|
||||
@@ -47,28 +45,20 @@ options:
|
||||
description:
|
||||
- Username to connect to vcenter as.
|
||||
required: true
|
||||
default: null
|
||||
password:
|
||||
description:
|
||||
- Password of the user to connect to vcenter as.
|
||||
required: true
|
||||
default: null
|
||||
resource_pool:
|
||||
description:
|
||||
- The name of the resource_pool to create the VM in.
|
||||
required: false
|
||||
default: None
|
||||
cluster:
|
||||
description:
|
||||
- The name of the cluster to create the VM in. By default this is derived from the host you tell the module to build the guest on.
|
||||
required: false
|
||||
default: None
|
||||
esxi:
|
||||
description:
|
||||
- Dictionary which includes datacenter and hostname on which the VM should be created. For standalone ESXi hosts, ha-datacenter should be used as the
|
||||
datacenter name
|
||||
required: false
|
||||
default: null
|
||||
state:
|
||||
description:
|
||||
- Indicate desired state of the vm. 'reconfigured' only applies changes to 'vm_cdrom', 'memory_mb', and 'num_cpus' in vm_hardware parameter.
|
||||
@@ -80,62 +70,48 @@ options:
|
||||
description:
|
||||
- Specifies if the VM should be deployed from a template (mutually exclusive with 'state' parameter). No guest customization changes to hardware
|
||||
such as CPU, RAM, NICs or Disks can be applied when launching from template.
|
||||
default: no
|
||||
type: bool
|
||||
default: 'no'
|
||||
template_src:
|
||||
version_added: "1.9"
|
||||
description:
|
||||
- Name of the source template to deploy from
|
||||
default: None
|
||||
snapshot_to_clone:
|
||||
description:
|
||||
- A string that when specified, will create a linked clone copy of the VM. Snapshot must already be taken in vCenter.
|
||||
version_added: "2.0"
|
||||
required: false
|
||||
default: none
|
||||
power_on_after_clone:
|
||||
description:
|
||||
- Specifies if the VM should be powered on after the clone.
|
||||
required: false
|
||||
default: yes
|
||||
type: bool
|
||||
default: 'yes'
|
||||
vm_disk:
|
||||
description:
|
||||
- A key, value list of disks and their sizes and which datastore to keep it in.
|
||||
required: false
|
||||
default: null
|
||||
vm_hardware:
|
||||
description:
|
||||
- A key, value list of VM config settings. Must include ['memory_mb', 'num_cpus', 'osid', 'scsi'].
|
||||
required: false
|
||||
default: null
|
||||
vm_nic:
|
||||
description:
|
||||
- A key, value list of nics, their types and what network to put them on. Optionaly with their MAC address.
|
||||
required: false
|
||||
default: null
|
||||
- A key, value list of nics, their types and what network to put them on.
|
||||
- Optionaly with their MAC address.
|
||||
vm_extra_config:
|
||||
description:
|
||||
- A key, value pair of any extra values you want set or changed in the vmx file of the VM. Useful to set advanced options on the VM.
|
||||
required: false
|
||||
default: null
|
||||
vm_hw_version:
|
||||
description:
|
||||
- Desired hardware version identifier (for example, "vmx-08" for vms that needs to be managed with vSphere Client). Note that changing hardware
|
||||
version of existing vm is not supported.
|
||||
required: false
|
||||
default: null
|
||||
version_added: "1.7"
|
||||
vmware_guest_facts:
|
||||
description:
|
||||
- Gather facts from vCenter on a particular VM
|
||||
type: bool
|
||||
default: null
|
||||
force:
|
||||
description:
|
||||
- Boolean. Allows you to run commands which may alter the running state of a guest. Also used to reconfigure and destroy.
|
||||
default: "no"
|
||||
type: bool
|
||||
default: 'no'
|
||||
|
||||
notes:
|
||||
- This module should run from a system that can access vSphere directly.
|
||||
|
||||
@@ -31,94 +31,67 @@ options:
|
||||
the I(state) is not `absent` then the I(template_name) value must be
|
||||
provided. The I(template_name) must be previously uploaded to the
|
||||
catalog specified by I(catalog_name)
|
||||
required: no
|
||||
default: None
|
||||
network_name:
|
||||
description:
|
||||
- The name of the network that should be attached to the virtual machine
|
||||
in the vApp. The virtual network specified must already be created in
|
||||
the vCloud Air VDC. If the I(state) is not 'absent' then the
|
||||
I(network_name) argument must be provided.
|
||||
required: no
|
||||
default: None
|
||||
network_mode:
|
||||
description:
|
||||
- Configures the mode of the network connection.
|
||||
required: no
|
||||
default: pool
|
||||
choices: ['pool', 'dhcp', 'static']
|
||||
vm_name:
|
||||
description:
|
||||
- The name of the virtual machine instance in the vApp to manage.
|
||||
required: no
|
||||
default: None
|
||||
vm_cpus:
|
||||
description:
|
||||
- The number of vCPUs to configure for the VM in the vApp. If the
|
||||
I(vm_name) argument is provided, then this becomes a per VM setting
|
||||
otherwise it is applied to all VMs in the vApp.
|
||||
required: no
|
||||
default: None
|
||||
vm_memory:
|
||||
description:
|
||||
- The amount of memory in MB to allocate to VMs in the vApp. If the
|
||||
I(vm_name) argument is provided, then this becomes a per VM setting
|
||||
otherise it is applied to all VMs in the vApp.
|
||||
required: no
|
||||
default: None
|
||||
operation:
|
||||
description:
|
||||
- Specifies an operation to be performed on the vApp.
|
||||
required: no
|
||||
default: noop
|
||||
choices: ['noop', 'poweron', 'poweroff', 'suspend', 'shutdown', 'reboot', 'reset']
|
||||
state:
|
||||
description:
|
||||
- Configures the state of the vApp.
|
||||
required: no
|
||||
default: present
|
||||
choices: ['present', 'absent', 'deployed', 'undeployed']
|
||||
username:
|
||||
description:
|
||||
- The vCloud Air username to use during authentication
|
||||
required: false
|
||||
default: None
|
||||
password:
|
||||
description:
|
||||
- The vCloud Air password to use during authentication
|
||||
required: false
|
||||
default: None
|
||||
org:
|
||||
description:
|
||||
- The org to login to for creating vapp, mostly set when the service_type is vdc.
|
||||
required: false
|
||||
default: None
|
||||
instance_id:
|
||||
description:
|
||||
- The instance id in a vchs environment to be used for creating the vapp
|
||||
required: false
|
||||
default: None
|
||||
host:
|
||||
description:
|
||||
- The authentication host to be used when service type is vcd.
|
||||
required: false
|
||||
default: None
|
||||
api_version:
|
||||
description:
|
||||
- The api version to be used with the vca
|
||||
required: false
|
||||
default: "5.7"
|
||||
service_type:
|
||||
description:
|
||||
- The type of service we are authenticating against
|
||||
required: false
|
||||
default: vca
|
||||
choices: [ "vca", "vchs", "vcd" ]
|
||||
vdc_name:
|
||||
description:
|
||||
- The name of the virtual data center (VDC) where the vm should be created or contains the vAPP.
|
||||
required: false
|
||||
default: None
|
||||
extends_documentation_fragment: vca
|
||||
'''
|
||||
|
||||
|
||||
Reference in New Issue
Block a user