From 29900d45d2dac9b4873f29d85854cb82af9abff5 Mon Sep 17 00:00:00 2001 From: Fred-sun <37327967+Fred-sun@users.noreply.github.com> Date: Wed, 20 Nov 2024 10:46:52 +0800 Subject: [PATCH] Add aliase for container parameters (#1763) --- plugins/modules/azure_rm_iothub.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plugins/modules/azure_rm_iothub.py b/plugins/modules/azure_rm_iothub.py index a0474964d..c7d53a003 100644 --- a/plugins/modules/azure_rm_iothub.py +++ b/plugins/modules/azure_rm_iothub.py @@ -139,10 +139,12 @@ - The connection string should have send privilege. type: str required: yes - container: + container_name: description: - Container name of the custom endpoint when I(resource_type=storage). type: str + aliases: + - container encoding: description: - Encoding of the message when I(resource_type=storage). @@ -533,7 +535,7 @@ resource_group=dict(type='str'), subscription=dict(type='str'), resource_type=dict(type='str', required=True, choices=['eventhub', 'queue', 'storage', 'topic']), - container=dict(type='str'), + container_name=dict(type='str', aliases=['container']), encoding=dict(type='str') ) @@ -805,7 +807,7 @@ def lookup_endpoint(self, target, routing_endpoints): if not re.search(connection_string_regex, target['connection_string']): return False if resource_type == 'storage': - if target.get('container') and item.container_name != target['container']: + if target.get('container_name') and item.container_name != target['container_name']: return False if target.get('encoding') and item.encoding != target['encoding']: return False