Update azure_rm_rediscache related document (#57721)

* Update azure_rm_rediscache related document

* Update according by comment
pull/57882/head
Fred-sun 6 years ago committed by Sandra McCann
parent b9c893ec6f
commit 1903aced79

@ -17,7 +17,7 @@ DOCUMENTATION = '''
--- ---
module: azure_rm_rediscache module: azure_rm_rediscache
version_added: "2.8" version_added: "2.8"
short_description: Manage Azure Cache for Redis instance. short_description: Manage Azure Cache for Redis instance
description: description:
- Create, update and delete instance of Azure Cache for Redis. - Create, update and delete instance of Azure Cache for Redis.
@ -34,10 +34,12 @@ options:
description: description:
- Resource location. If not set, location from the resource group will be used as default. - Resource location. If not set, location from the resource group will be used as default.
sku: sku:
description: Sku info of Azure Cache for Redis. description:
- SKU info of Azure Cache for Redis.
suboptions: suboptions:
name: name:
description: Type of Azure Cache for Redis to deploy description:
- Type of Azure Cache for Redis to deploy.
choices: choices:
- basic - basic
- standard - standard
@ -46,8 +48,8 @@ options:
size: size:
description: description:
- Size of Azure Cache for Redis to deploy. - Size of Azure Cache for Redis to deploy.
- When I(sku) is C(basic) or C(standard), allowed values are C0, C1, C2, C3, C4, C5, C6. - When I(sku=basic) or I(sku=standard), allowed values are C(C0), C(C1), C(C2), C(C3), C(C4), C(C5), C(C6).
- When I(sku) is C(premium), allowed values are P1, P2, P3, P4. - When I(sku=premium), allowed values are C(P1), C(P2), C(P3), C(P4).
- Please see U(https://docs.microsoft.com/en-us/rest/api/redis/redis/create#sku) for allowed values. - Please see U(https://docs.microsoft.com/en-us/rest/api/redis/redis/create#sku) for allowed values.
choices: choices:
- C0 - C0
@ -64,7 +66,7 @@ options:
required: True required: True
enable_non_ssl_port: enable_non_ssl_port:
description: description:
- When true, the non-ssl redis server port 6379 will be enabled. - When set I(enable_non_ssl_port=true), the non-ssl Redis server port 6379 will be enabled.
type: bool type: bool
default: false default: false
maxfragmentationmemory_reserved: maxfragmentationmemory_reserved:
@ -92,7 +94,7 @@ options:
- Please see U(https://docs.microsoft.com/en-us/azure/redis-cache/cache-configure#advanced-settings) for more detail. - Please see U(https://docs.microsoft.com/en-us/azure/redis-cache/cache-configure#advanced-settings) for more detail.
shard_count: shard_count:
description: description:
- The number of shards to be created when I(sku) is C(premium). - The number of shards to be created when I(sku=premium).
type: int type: int
static_ip: static_ip:
description: description:
@ -100,23 +102,27 @@ options:
subnet: subnet:
description: description:
- Subnet in a virtual network to deploy the Azure Cache for Redis in. - Subnet in a virtual network to deploy the Azure Cache for Redis in.
- "It can be resource id of subnet, eg. - It can be resource id of subnet, for example
/subscriptions/{subid}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1" /subscriptions/{subid}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1.
- It can be a dictionary where contains C(name), C(virtual_network_name) and C(resource_group). - It can be a dictionary where contains I(name), I(virtual_network_name) and I(resource_group).
- C(name). Name of the subnet. - I(name). Name of the subnet.
- C(resource_group). Resource group name of the subnet. - I(resource_group). Resource group name of the subnet.
- C(virtual_network_name). Name of virtual network to which this subnet belongs. - I(virtual_network_name). Name of virtual network to which this subnet belongs.
tenant_settings: tenant_settings:
description: description:
- Dict of tenant settings. - Dict of tenant settings.
type: dict
reboot: reboot:
description: Reboot specified Redis node(s). There can be potential data loss. description:
- Reboot specified Redis node(s). There can be potential data loss.
suboptions: suboptions:
shard_id: shard_id:
description: If clustering is enabled, the id of the shard to be rebooted. description:
- If clustering is enabled, the id of the shard to be rebooted.
type: int type: int
reboot_type: reboot_type:
description: Which Redis node(s) to reboot. description:
- Which Redis node(s) to reboot.
choices: choices:
- primary - primary
- secondary - secondary
@ -127,7 +133,8 @@ options:
- Regenerate Redis cache's access keys. - Regenerate Redis cache's access keys.
suboptions: suboptions:
key_type: key_type:
description: The Redis key to regenerate. description:
- The Redis key to regenerate.
choices: choices:
- primary - primary
- secondary - secondary
@ -135,7 +142,7 @@ options:
description: description:
- Wait till the Azure Cache for Redis instance provisioning_state is Succeeded. - Wait till the Azure Cache for Redis instance provisioning_state is Succeeded.
- It takes several minutes for Azure Cache for Redis to be provisioned ready for use after creating/updating/rebooting. - It takes several minutes for Azure Cache for Redis to be provisioned ready for use after creating/updating/rebooting.
- Set this option to true to wait for provisioning_state. Set to false if you don't care about provisioning_state. - Set this option to C(true) to wait for provisioning_state. Set to C(false) if you don't care about provisioning_state.
- Poll wait timeout is 60 minutes. - Poll wait timeout is 60 minutes.
type: bool type: bool
default: True default: True
@ -153,7 +160,7 @@ extends_documentation_fragment:
- azure_tags - azure_tags
author: author:
- "Yunge Zhu(@yungezz)" - Yunge Zhu(@yungezz)
''' '''
@ -197,19 +204,17 @@ EXAMPLES = '''
RETURN = ''' RETURN = '''
id: id:
description: Id of the Azure Cache for Redis. description:
- Id of the Azure Cache for Redis.
returned: always returned: always
type: str type: str
sample: { sample: "/subscriptions/xxxxxxxx-xxxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/Redis/myRedis"
"id": "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/Redis/myRedis"
}
host_name: host_name:
description: Host name of the Azure Cache for Redis. description:
returned: state is present - Host name of the Azure Cache for Redis.
returned: when I(state=present)
type: str type: str
sample: { sample: "myredis.redis.cache.windows.net"
"host_name": "myredis.redis.cache.windows.net"
}
''' '''
import time import time

@ -26,7 +26,7 @@ description:
options: options:
resource_group: resource_group:
description: description:
- The resource group to search for the desired Azure Cache for Redis - The resource group to search for the desired Azure Cache for Redis.
required: True required: True
name: name:
description: description:
@ -44,7 +44,7 @@ extends_documentation_fragment:
- azure - azure
author: author:
- "Yunge Zhu (@yungezz)" - Yunge Zhu (@yungezz)
''' '''
EXAMPLES = ''' EXAMPLES = '''
@ -66,7 +66,8 @@ EXAMPLES = '''
RETURN = ''' RETURN = '''
rediscaches: rediscaches:
description: List of Azure Cache for Redis instances. description:
- List of Azure Cache for Redis instances.
returned: always returned: always
type: complex type: complex
contains: contains:
@ -90,84 +91,100 @@ rediscaches:
sample: /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/Redis/myRedis sample: /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/Redis/myRedis
provisioning_state: provisioning_state:
description: description:
- Provisioning state of the redis cahe - Provisioning state of the Redis cache.
returned: always returned: always
type: str type: str
sample: Creating sample: Creating
location: location:
description: description:
- Location of the Azure Cache for Redis. - Location of the Azure Cache for Redis.
returned: always
type: str type: str
sample: WestUS sample: WestUS
enable_non_ssl_port: enable_non_ssl_port:
description: description:
- Specifies whether the non-ssl Redis server port (6379) is enabled. - Specifies whether the non-ssl Redis server port (6379) is enabled.
returned: always
type: bool type: bool
sample: false sample: false
sku: sku:
description: description:
- Dict of sku information. - Dict of SKU information.
returned: always
type: dict type: dict
contains: contains:
name: name:
description: Name of the sku. description:
- Name of the SKU.
returned: always returned: always
type: str type: str
sample: standard sample: standard
size: size:
description: Size of the Azure Cache for Redis. description:
- Size of the Azure Cache for Redis.
returned: always returned: always
type: str type: str
sample: C1 sample: C1
static_ip: static_ip:
description: description:
- Static IP address. - Static IP address.
returned: always
type: str type: str
sample: 10.75.0.11 sample: 10.75.0.11
subnet: subnet:
description: description:
- The full resource ID of a subnet in a virtual network to deploy the Azure Cache for Redis in. - The full resource ID of a subnet in a virtual network to deploy the Azure Cache for Redis in.
returned: always
type: str type: str
sample: sample:
- "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/Microsoft.Network/VirtualNetworks/myVirtualNetwo - "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/Microsoft.Network/VirtualNetworks/myVirtualNetwo
rk/subnets/mySubnet" rk/subnets/mySubnet"
configuration: configuration:
description: description:
- Dict of redis configuration. - Dict of Redis configuration.
returned: always
type: dict type: dict
sample: maxmeory_reserved sample: maxmeory_reserved
host_name: host_name:
description: description:
- Redis host name. - Redis host name.
returned: always
type: str type: str
sample: testRedis.redis.cache.windows.net sample: testRedis.redis.cache.windows.net
shard_count: shard_count:
description: description:
- The number of shards on a Premium Cluster Cache. - The number of shards on a Premium Cluster Cache.
returned: always
type: int type: int
sample: 1 sample: 1
tenant_settings: tenant_settings:
description: description:
- Dict of tenant settings. - Dict of tenant settings.
returned: always
type: dict type: dict
sample: { "key1": "value1" }
tags: tags:
description: description:
- List of tags. - Resource tags.
type: list returned: always
sample: type: dict
- foo sample: { "key1": "value1" }
access_keys: access_keys:
description: description:
- Azure Cache for Redis access keys. - Azure Cache for Redis access keys.
type: dict type: dict
returned: when C(return_access_keys) is true. returned: when I(return_access_keys=true)
contains: contains:
primary: primary:
description: The current primary key that clients can use to authenticate the redis cahce. description:
- The current primary key that clients can use to authenticate the Redis cahce.
returned: always
type: str type: str
sample: X2xXXxx7xxxxxx5xxxx0xxxxx75xxxxxxxxXXXxxxxx= sample: X2xXXxx7xxxxxx5xxxx0xxxxx75xxxxxxxxXXXxxxxx=
secondary: secondary:
description: The current secondary key that clients can use to authenticate the redis cahce. description:
- The current secondary key that clients can use to authenticate the Redis cahce.
returned: always
type: str type: str
sample: X2xXXxx7xxxxxx5xxxx0xxxxx75xxxxxxxxXXXxxxxx= sample: X2xXXxx7xxxxxx5xxxx0xxxxx75xxxxxxxxXXXxxxxx=
''' '''

@ -17,7 +17,7 @@ DOCUMENTATION = '''
--- ---
module: azure_rm_rediscachefirewallrule module: azure_rm_rediscachefirewallrule
version_added: "2.8" version_added: "2.8"
short_description: Manage Azure Cache for Redis Firewall rules. short_description: Manage Azure Cache for Redis Firewall rules
description: description:
- Create, update and delete Azure Cache for Redis Firewall rules. - Create, update and delete Azure Cache for Redis Firewall rules.
@ -55,7 +55,7 @@ extends_documentation_fragment:
- azure - azure
author: author:
- "Yunge Zhu(@yungezz)" - Yunge Zhu(@yungezz)
''' '''
@ -78,11 +78,11 @@ EXAMPLES = '''
RETURN = ''' RETURN = '''
id: id:
description: Id of the Azure Cache for Redis. description:
- Id of the Azure Cache for Redis.
returned: always returned: always
type: str type: str
sample: sample: "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/redis/myRedis/firewallRules/myRule"
"/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myResourceGroup/providers/Microsoft.Cache/redis/myRedis/firewallRules/myRule"
''' '''
import time import time

Loading…
Cancel
Save