mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-26 12:21:26 -07:00
Bulk autopep8 (modules)
As agreed in 2017-12-07 Core meeting bulk fix pep8 issues Generated using: autopep8 1.3.3 (pycodestyle: 2.3.1) autopep8 -r --max-line-length 160 --in-place --ignore E305,E402,E722,E741 lib/ansible/modules Manually fix issues that autopep8 has introduced
This commit is contained in:
parent
d13d7e9404
commit
c57a7f05e1
314 changed files with 3462 additions and 3383 deletions
|
@ -219,7 +219,7 @@ state:
|
|||
try:
|
||||
from msrestazure.azure_exceptions import CloudError
|
||||
from azure.mgmt.network.models import NetworkInterface, NetworkInterfaceIPConfiguration, Subnet, \
|
||||
PublicIPAddress, NetworkSecurityGroup
|
||||
PublicIPAddress, NetworkSecurityGroup
|
||||
except ImportError:
|
||||
# This is handled in azure_rm_common
|
||||
pass
|
||||
|
@ -442,7 +442,7 @@ class AzureRMNetworkInterface(AzureRMModuleBase):
|
|||
if not pip and self.public_ip:
|
||||
# create a default public_ip
|
||||
pip = self.create_default_pip(self.resource_group, self.location, self.name,
|
||||
self.public_ip_allocation_method)
|
||||
self.public_ip_allocation_method)
|
||||
|
||||
nic = NetworkInterface(
|
||||
location=self.location,
|
||||
|
@ -475,8 +475,7 @@ class AzureRMNetworkInterface(AzureRMModuleBase):
|
|||
tags=results['tags'],
|
||||
ip_configurations=[
|
||||
NetworkInterfaceIPConfiguration(
|
||||
private_ip_allocation_method=
|
||||
results['ip_configuration']['private_ip_allocation_method']
|
||||
private_ip_allocation_method=results['ip_configuration']['private_ip_allocation_method']
|
||||
)
|
||||
]
|
||||
)
|
||||
|
@ -496,7 +495,7 @@ class AzureRMNetworkInterface(AzureRMModuleBase):
|
|||
id=pip.id,
|
||||
location=pip.location,
|
||||
resource_guid=pip.resource_guid)
|
||||
#name=pip.name,
|
||||
# name=pip.name,
|
||||
|
||||
if results['network_security_group'].get('id'):
|
||||
nsg = self.get_security_group(results['network_security_group']['name'])
|
||||
|
@ -549,8 +548,8 @@ class AzureRMNetworkInterface(AzureRMModuleBase):
|
|||
subnet = self.network_client.subnets.get(self.resource_group, vnet_name, subnet_name)
|
||||
except Exception as exc:
|
||||
self.fail("Error: fetching subnet {0} in virtual network {1} - {2}".format(subnet_name,
|
||||
vnet_name,
|
||||
str(exc)))
|
||||
vnet_name,
|
||||
str(exc)))
|
||||
return subnet
|
||||
|
||||
def get_security_group(self, name):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue