diff --git a/lib/ansible/modules/cloud/azure/azure_rm_loadbalancer.py b/lib/ansible/modules/cloud/azure/azure_rm_loadbalancer.py index 652a21c129..8b8e7bd5a1 100755 --- a/lib/ansible/modules/cloud/azure/azure_rm_loadbalancer.py +++ b/lib/ansible/modules/cloud/azure/azure_rm_loadbalancer.py @@ -426,7 +426,7 @@ class AzureRMLoadBalancer(AzureRMModuleBase): load_balancer_props['inbound_nat_pools'] = [ self.network_models.InboundNatPool( name=inbound_nat_pool_name, - frontend_ip_configuration=Subnet(id=frontend_ip_config_id), + frontend_ip_configuration=self.network_models.Subnet(id=frontend_ip_config_id), protocol=self.natpool_protocol, frontend_port_range_start=self.natpool_frontend_port_start, frontend_port_range_end=self.natpool_frontend_port_end,