use the same C() everywhere for absent / present options (#52610)

* use the same C() everywhere for absent / present options

* Update lib/ansible/modules/cloud/azure/azure_rm_cdnendpoint.py

* Update lib/ansible/modules/cloud/azure/azure_rm_resourcegroup.py

* Update lib/ansible/modules/cloud/azure/azure_rm_cdnendpoint.py

* Update lib/ansible/modules/cloud/azure/azure_rm_cdnendpoint.py

Co-Authored-By: zikalino <zikalino@microsoft.com>
pull/52519/head
Zim Kalinowski 6 years ago committed by Alicia Cozine
parent a722133640
commit 053081a8a0

@ -31,7 +31,7 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the ACS. Use 'present' to create or update an ACS and 'absent' to delete it. - Assert the state of the ACS. Use C(present) to create or update an ACS and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -357,8 +357,8 @@ options:
- Redirect configuration resource of the application gateway - Redirect configuration resource of the application gateway
state: state:
description: description:
- Assert the state of the Public IP. Use 'present' to create or update a and - Assert the state of the Public IP. Use C(present) to create or update a and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -36,7 +36,7 @@ options:
state: state:
description: description:
- Assert the state of the Application Security Group. - Assert the state of the Application Security Group.
- Use 'present' to create or update an Application Security Group and 'absent' to delete it. - Use C(present) to create or update an Application Security Group and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -55,7 +55,7 @@ options:
state: state:
description: description:
- Assert the state of the app service plan. - Assert the state of the app service plan.
- Use 'present' to create or update an app service plan and 'absent' to delete it. - Use C(present) to create or update an app service plan and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -179,7 +179,7 @@ options:
description: A value indicating whether to send email to subscription co-administrators. description: A value indicating whether to send email to subscription co-administrators.
state: state:
default: present default: present
description: Assert the state of the virtual network. Use 'present' to create or update and 'absent' to delete. description: Assert the state of the virtual network. Use C(present) to create or update and C(absent) to delete.
choices: choices:
- present - present
- absent - absent

@ -35,8 +35,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the availability set. Use 'present' to create or update a availability set and - Assert the state of the availability set. Use C(present) to create or update a availability set and
'absent' to delete a availability set. C(absent) to delete a availability set.
default: present default: present
choices: choices:
- absent - absent

@ -33,16 +33,16 @@ options:
- Valid azure location. Defaults to location of the resource group. - Valid azure location. Defaults to location of the resource group.
started: started:
description: description:
- Use with I(state) 'present' to start the endpoint. Set to false to stop the endpoint. Set to true to start the endpoint. - Use with I(state) C(present) to start the endpoint. Set to C(false) to stop the endpoint. Set to C(true) to start the endpoint.
type: bool type: bool
purge: purge:
description: description:
- Use with I(state) 'present' to purge the endpoint. Set to true to have the endpoint be purged. - Use with I(state) C(present) to purge the endpoint. Set to C(true) to have the endpoint be purged.
type: bool type: bool
default: false default: false
purge_content_paths: purge_content_paths:
description: description:
- Use with I(state) 'present' and I(purge) 'true' to specify content paths to be purged. - Use with I(state) C(present) and I(purge) C(true) to specify content paths to be purged.
type: list type: list
default: ['/'] default: ['/']
profile_name: profile_name:

@ -39,7 +39,7 @@ options:
default: linux default: linux
state: state:
description: description:
- Assert the state of the container instance. Use 'present' to create or update an container instance and 'absent' to delete it. - Assert the state of the container instance. Use C(present) to create or update an container instance and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -30,7 +30,7 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the container registry. Use 'present' to create or update an container registry and 'absent' to delete it. - Assert the state of the container registry. Use C(present) to create or update an container registry and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -129,7 +129,7 @@ options:
state: state:
description: description:
- Assert the state of the Database Account. - Assert the state of the Database Account.
- Use 'present' to create or update an Database Account and 'absent' to delete it. - Use C(present) to create or update an Database Account and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -43,7 +43,7 @@ options:
state: state:
description: description:
- Assert the state of the Virtual Network. - Assert the state of the Virtual Network.
- Use 'present' to create or update an Virtual Network and 'absent' to delete it. - Use C(present) to create or update an Virtual Network and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -47,8 +47,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the zone. Use 'present' to create or update and - Assert the state of the zone. Use C(present) to create or update and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -46,8 +46,8 @@ options:
- Dictionary containing application settings - Dictionary containing application settings
state: state:
description: description:
- Assert the state of the Function App. Use 'present' to create or update a Function App and - Assert the state of the Function App. Use C(present) to create or update a Function App and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -143,7 +143,7 @@ options:
type: bool type: bool
state: state:
description: description:
- Assert the state of the KeyVault. Use 'present' to create or update an KeyVault and 'absent' to delete it. - Assert the state of the KeyVault. Use C(present) to create or update an KeyVault and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -39,8 +39,8 @@ options:
- PEM password. - PEM password.
state: state:
description: description:
- Assert the state of the key. Use 'present' to create a key and - Assert the state of the key. Use C(present) to create a key and
'absent' to delete a key. C(absent) to delete a key.
default: present default: present
choices: choices:
- absent - absent

@ -33,8 +33,8 @@ options:
- Secret to be secured by keyvault. - Secret to be secured by keyvault.
state: state:
description: description:
- Assert the state of the subnet. Use 'present' to create or update a secret and - Assert the state of the subnet. Use C(present) to create or update a secret and
'absent' to delete a secret . C(absent) to delete a secret .
default: present default: present
choices: choices:
- absent - absent

@ -35,7 +35,7 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the managed disk. Use C(present) to create or update a managed disk and 'absent' to delete a managed disk. - Assert the state of the managed disk. Use C(present) to create or update a managed disk and C(absent) to delete a managed disk.
default: present default: present
choices: choices:
- absent - absent

@ -54,7 +54,7 @@ options:
default: 'no' default: 'no'
state: state:
description: description:
- Assert the state of the MySQL Database. Use 'present' to create or update a database and 'absent' to delete it. - Assert the state of the MySQL Database. Use C(present) to create or update a database and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -42,7 +42,7 @@ options:
- The end IP address of the MySQL firewall rule. Must be IPv4 format. - The end IP address of the MySQL firewall rule. Must be IPv4 format.
state: state:
description: description:
- Assert the state of the MySQL firewall rule. Use 'present' to create or update a rule and 'absent' to ensure it is not present. - Assert the state of the MySQL firewall rule. Use C(present) to create or update a rule and C(absent) to ensure it is not present.
default: present default: present
choices: choices:
- absent - absent

@ -74,7 +74,7 @@ options:
default: Default default: Default
state: state:
description: description:
- Assert the state of the MySQL Server. Use 'present' to create or update a server and 'absent' to delete it. - Assert the state of the MySQL Server. Use C(present) to create or update a server and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -40,8 +40,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the network interface. Use 'present' to create or update an interface and - Assert the state of the network interface. Use C(present) to create or update an interface and
'absent' to delete an interface. C(absent) to delete an interface.
default: present default: present
choices: choices:
- absent - absent

@ -54,7 +54,7 @@ options:
default: 'no' default: 'no'
state: state:
description: description:
- Assert the state of the PostgreSQL database. Use 'present' to create or update a database and 'absent' to delete it. - Assert the state of the PostgreSQL database. Use C(present) to create or update a database and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -42,7 +42,7 @@ options:
- The end IP address of the PostgreSQL firewall rule. Must be IPv4 format. - The end IP address of the PostgreSQL firewall rule. Must be IPv4 format.
state: state:
description: description:
- Assert the state of the PostgreSQL firewall rule. Use 'present' to create or update a PostgreSQL firewall rule and 'absent' to delete it. - Assert the state of the PostgreSQL firewall rule. Use C(present) to create or update a PostgreSQL firewall rule and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -74,7 +74,7 @@ options:
default: Default default: Default
state: state:
description: description:
- Assert the state of the PostgreSQL server. Use 'present' to create or update a server and 'absent' to delete it. - Assert the state of the PostgreSQL server. Use C(present) to create or update a server and C(absent) to delete it.
default: present default: present
choices: choices:
- present - present

@ -53,8 +53,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the Public IP. Use 'present' to create or update a and - Assert the state of the Public IP. Use C(present) to create or update a and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -113,7 +113,7 @@ options:
state: state:
description: description:
- Assert the state of the redis cache. - Assert the state of the redis cache.
- Use 'present' to create or update a redis cache and 'absent' to delete it. - Use C(present) to create or update a redis cache and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -24,7 +24,7 @@ description:
options: options:
force_delete_nonempty: force_delete_nonempty:
description: description:
- Remove a resource group and all associated resources. Use with state 'absent' to delete a resource - Remove a resource group and all associated resources. Use with state C(absent) to delete a resource.
group that contains resources. group that contains resources.
type: bool type: bool
aliases: aliases:
@ -40,8 +40,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the resource group. Use 'present' to create or update and - Assert the state of the resource group. Use C(present) to create or update and
'absent' to delete. When 'absent' a resource group containing resources will not be removed unless the C(absent) to delete. When C(absent) a resource group containing resources will not be removed unless the
force option is used. force option is used.
default: present default: present
choices: choices:

@ -31,8 +31,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the route. Use 'present' to create or update and - Assert the state of the route. Use C(present) to create or update and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -31,8 +31,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the route table. Use 'present' to create or update and - Assert the state of the route table. Use C(present) to create or update and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -115,8 +115,8 @@ options:
default: Inbound default: Inbound
state: state:
description: description:
- Assert the state of the security group. Set to 'present' to create or update a security group. Set to - Assert the state of the security group. Set to C(present) to create or update a security group. Set to
'absent' to remove a security group. C(absent) to remove a security group.
default: present default: present
choices: choices:
- absent - absent

@ -127,7 +127,7 @@ options:
type: bool type: bool
state: state:
description: description:
- Assert the state of the SQL Database. Use 'present' to create or update an SQL Database and 'absent' to delete it. - Assert the state of the SQL Database. Use C(present) to create or update an SQL Database and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -43,7 +43,7 @@ options:
nt all Azure-internal IP addresses." nt all Azure-internal IP addresses."
state: state:
description: description:
- Assert the state of the SQL Database. Use 'present' to create or update an SQL Database and 'absent' to delete it. - Assert the state of the SQL Database. Use C(present) to create or update an SQL Database and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -48,8 +48,8 @@ options:
ce. Possible values include: 'SystemAssigned'" ce. Possible values include: 'SystemAssigned'"
state: state:
description: description:
- Assert the state of the SQL server. Use 'present' to create or update a server and - Assert the state of the SQL server. Use C(present) to create or update a server and
'absent' to delete a server. C(absent) to delete a server.
default: present default: present
choices: choices:
- absent - absent

@ -33,8 +33,8 @@ options:
- Name of the storage account to update or create. - Name of the storage account to update or create.
state: state:
description: description:
- Assert the state of the storage account. Use 'present' to create or update a storage account and - Assert the state of the storage account. Use C(present) to create or update a storage account and
'absent' to delete an account. C(absent) to delete an account.
default: present default: present
choices: choices:
- absent - absent

@ -69,7 +69,7 @@ options:
- Set the blob md5 hash value. - Set the blob md5 hash value.
dest: dest:
description: description:
- Destination file path. Use with state 'present' to download a blob. - Destination file path. Use with state C(present) to download a blob.
aliases: aliases:
- destination - destination
force: force:
@ -86,16 +86,16 @@ options:
- resource_group_name - resource_group_name
src: src:
description: description:
- Source file path. Use with state 'present' to upload a blob. - Source file path. Use with state C(present) to upload a blob.
aliases: aliases:
- source - source
state: state:
description: description:
- Assert the state of a container or blob. - Assert the state of a container or blob.
- Use state 'absent' with a container value only to delete a container. Include a blob value to remove - Use state C(absent) with a container value only to delete a container. Include a blob value to remove
a specific blob. A container will not be deleted, if it contains blobs. Use the force option to override, a specific blob. A container will not be deleted, if it contains blobs. Use the force option to override,
deleting the container and all associated blobs. deleting the container and all associated blobs.
- Use state 'present' to create or update a container and upload or download a blob. If the container - Use state C(present) to create or update a container and upload or download a blob. If the container
does not exist, it will be created. If it exists, it will be updated with configuration options. Provide does not exist, it will be created. If it exists, it will be updated with configuration options. Provide
a blob name and either src or dest to upload or download. Provide a src path to upload and a dest path a blob name and either src or dest to upload or download. Provide a src path to upload and a dest path
to download. If a blob (uploading) or a file (downloading) already exists, it will not be overwritten to download. If a blob (uploading) or a file (downloading) already exists, it will not be overwritten

@ -49,8 +49,8 @@ options:
- security_group_name - security_group_name
state: state:
description: description:
- Assert the state of the subnet. Use 'present' to create or update a subnet and - Assert the state of the subnet. Use C(present) to create or update a subnet and
'absent' to delete a subnet. C(absent) to delete a subnet.
default: present default: present
choices: choices:
- absent - absent

@ -50,17 +50,17 @@ options:
state: state:
description: description:
- Assert the state of the virtual machine. - Assert the state of the virtual machine.
- State 'present' will check that the machine exists with the requested configuration. If the configuration - State C(present) will check that the machine exists with the requested configuration. If the configuration
of the existing machine does not match, the machine will be updated. Use options started, allocated and restarted to change the machine's power of the existing machine does not match, the machine will be updated. Use options started, allocated and restarted to change the machine's power
state. state.
- State 'absent' will remove the virtual machine. - State C(absent) will remove the virtual machine.
default: present default: present
choices: choices:
- absent - absent
- present - present
started: started:
description: description:
- Use with state 'present' to start the machine. Set to false to have the machine be 'stopped'. - Use with state C(present) to start the machine. Set to false to have the machine be 'stopped'.
default: true default: true
type: bool type: bool
allocated: allocated:
@ -70,13 +70,13 @@ options:
type: bool type: bool
generalized: generalized:
description: description:
- Use with state 'present' to generalize the machine. Set to true to generalize the machine. - Use with state C(present) to generalize the machine. Set to true to generalize the machine.
- Please note that this operation is irreversible. - Please note that this operation is irreversible.
type: bool type: bool
version_added: "2.8" version_added: "2.8"
restarted: restarted:
description: description:
- Use with state 'present' to restart a running VM. - Use with state C(present) to restart a running VM.
type: bool type: bool
location: location:
description: description:

@ -35,8 +35,8 @@ options:
required: true required: true
state: state:
description: description:
- Assert the state of the vm extension. Use 'present' to create or update a vm extension and - Assert the state of the vm extension. Use C(present) to create or update a vm extension and
'absent' to delete a vm extension. C(absent) to delete a vm extension.
default: present default: present
choices: choices:
- absent - absent

@ -36,10 +36,10 @@ options:
state: state:
description: description:
- Assert the state of the virtual machine scale set. - Assert the state of the virtual machine scale set.
- State 'present' will check that the machine exists with the requested configuration. If the configuration - State C(present) will check that the machine exists with the requested configuration. If the configuration
of the existing machine does not match, the machine will be updated. of the existing machine does not match, the machine will be updated.
state. state.
- State 'absent' will remove the virtual machine scale set. - State C(absent) will remove the virtual machine scale set.
default: present default: present
choices: choices:
- absent - absent

@ -61,8 +61,8 @@ options:
default: 'no' default: 'no'
state: state:
description: description:
- Assert the state of the virtual network. Use 'present' to create or update and - Assert the state of the virtual network. Use C(present) to create or update and
'absent' to delete. C(absent) to delete.
default: present default: present
choices: choices:
- absent - absent

@ -171,7 +171,7 @@ options:
state: state:
description: description:
- Assert the state of the Web App. - Assert the state of the Web App.
- Use 'present' to create or update a Web App and 'absent' to delete it. - Use C(present) to create or update a Web App and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

@ -153,7 +153,7 @@ options:
state: state:
description: description:
- Assert the state of the Web App deployment slot. - Assert the state of the Web App deployment slot.
- Use 'present' to create or update a slot and 'absent' to delete it. - Use C(present) to create or update a slot and C(absent) to delete it.
default: present default: present
choices: choices:
- absent - absent

Loading…
Cancel
Save