mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-25 22:30:22 -07:00
parent
d0d1158c5e
commit
e2c0b375d3
23 changed files with 51 additions and 57 deletions
|
@ -387,8 +387,8 @@ def find_vgw(client, module, vpn_gateway_id=None):
|
|||
|
||||
def ensure_vgw_present(client, module):
|
||||
|
||||
# If an existing vgw name and type matches our args, then a match is considered to have been
|
||||
# found and we will not create another vgw.
|
||||
# If an existing vgw name and type matches our args, then a match is considered to have been
|
||||
# found and we will not create another vgw.
|
||||
|
||||
changed = False
|
||||
params = dict()
|
||||
|
@ -472,8 +472,8 @@ def ensure_vgw_present(client, module):
|
|||
|
||||
def ensure_vgw_absent(client, module):
|
||||
|
||||
# If an existing vgw name and type matches our args, then a match is considered to have been
|
||||
# found and we will take steps to delete it.
|
||||
# If an existing vgw name and type matches our args, then a match is considered to have been
|
||||
# found and we will take steps to delete it.
|
||||
|
||||
changed = False
|
||||
params = dict()
|
||||
|
|
|
@ -145,7 +145,7 @@ def main():
|
|||
exists = len(matching_groups) > 0
|
||||
except boto.exception.JSONResponseError as e:
|
||||
if e.body['Error']['Code'] != 'ClusterSubnetGroupNotFoundFault':
|
||||
#if e.code != 'ClusterSubnetGroupNotFoundFault':
|
||||
# if e.code != 'ClusterSubnetGroupNotFoundFault':
|
||||
module.fail_json(msg=str(e))
|
||||
|
||||
if state == 'absent':
|
||||
|
|
|
@ -601,7 +601,7 @@ def main():
|
|||
if mode == 'put':
|
||||
|
||||
# Use this snippet to debug through conditionals:
|
||||
# module.exit_json(msg="Bucket return %s"%bucketrtn)
|
||||
# module.exit_json(msg="Bucket return %s"%bucketrtn)
|
||||
|
||||
# Lets check the src path.
|
||||
pathrtn = path_check(src)
|
||||
|
|
|
@ -450,12 +450,12 @@ def main():
|
|||
except Exception as e:
|
||||
module.fail_json(msg=unexpected_error_msg(e), changed=False)
|
||||
if network:
|
||||
# json_output['d4'] = 'deleting %s' % name
|
||||
# json_output['d4'] = 'deleting %s' % name
|
||||
try:
|
||||
gce.ex_destroy_network(network)
|
||||
except Exception as e:
|
||||
module.fail_json(msg=unexpected_error_msg(e), changed=False)
|
||||
# json_output['d5'] = 'deleted %s' % name
|
||||
# json_output['d5'] = 'deleted %s' % name
|
||||
changed = True
|
||||
|
||||
json_output['changed'] = changed
|
||||
|
|
|
@ -296,21 +296,21 @@ def load_mongocnf():
|
|||
|
||||
|
||||
def check_if_roles_changed(uinfo, roles, db_name):
|
||||
# We must be aware of users which can read the oplog on a replicaset
|
||||
# Such users must have access to the local DB, but since this DB does not store users credentials
|
||||
# and is not synchronized among replica sets, the user must be stored on the admin db
|
||||
# Therefore their structure is the following :
|
||||
# {
|
||||
# "_id" : "admin.oplog_reader",
|
||||
# "user" : "oplog_reader",
|
||||
# "db" : "admin", # <-- admin DB
|
||||
# "roles" : [
|
||||
# {
|
||||
# "role" : "read",
|
||||
# "db" : "local" # <-- local DB
|
||||
# }
|
||||
# ]
|
||||
# }
|
||||
# We must be aware of users which can read the oplog on a replicaset
|
||||
# Such users must have access to the local DB, but since this DB does not store users credentials
|
||||
# and is not synchronized among replica sets, the user must be stored on the admin db
|
||||
# Therefore their structure is the following :
|
||||
# {
|
||||
# "_id" : "admin.oplog_reader",
|
||||
# "user" : "oplog_reader",
|
||||
# "db" : "admin", # <-- admin DB
|
||||
# "roles" : [
|
||||
# {
|
||||
# "role" : "read",
|
||||
# "db" : "local" # <-- local DB
|
||||
# }
|
||||
# ]
|
||||
# }
|
||||
|
||||
def make_sure_roles_are_a_list_of_dict(roles, db_name):
|
||||
output = list()
|
||||
|
|
|
@ -635,7 +635,7 @@ class TgzArchive(object):
|
|||
|
||||
for filename in out.splitlines():
|
||||
# Compensate for locale-related problems in gtar output (octal unicode representation) #11348
|
||||
# filename = filename.decode('string_escape')
|
||||
# filename = filename.decode('string_escape')
|
||||
filename = codecs.escape_decode(filename)[0]
|
||||
if filename and filename not in self.excludes:
|
||||
self._files_in_archive.append(to_native(filename))
|
||||
|
|
|
@ -299,8 +299,7 @@ def create_maintenance(auth_headers, url, statuspage, host_ids,
|
|||
"statuspage_id": statuspage,
|
||||
"components": component_id,
|
||||
"containers": container_id,
|
||||
"all_infrastructure_affected":
|
||||
str(int(all_infrastructure_affected)),
|
||||
"all_infrastructure_affected": str(int(all_infrastructure_affected)),
|
||||
"automation": str(int(automation)),
|
||||
"maintenance_name": title,
|
||||
"maintenance_details": desc,
|
||||
|
|
|
@ -419,8 +419,7 @@ def validate_feature(module, mode='show'):
|
|||
'ethernet-link-oam': 'elo',
|
||||
'port-security': 'eth_port_sec'
|
||||
},
|
||||
'config':
|
||||
{
|
||||
'config': {
|
||||
'nve': 'nv overlay',
|
||||
'vnseg_vlan': 'vn-segment-vlan-based',
|
||||
'hsrp_engine': 'hsrp',
|
||||
|
|
|
@ -107,7 +107,6 @@ lib/ansible/modules/cloud/amazon/rds.py
|
|||
lib/ansible/modules/cloud/amazon/rds_param_group.py
|
||||
lib/ansible/modules/cloud/amazon/rds_subnet_group.py
|
||||
lib/ansible/modules/cloud/amazon/redshift.py
|
||||
lib/ansible/modules/cloud/amazon/redshift_subnet_group.py
|
||||
lib/ansible/modules/cloud/amazon/route53.py
|
||||
lib/ansible/modules/cloud/amazon/route53_health_check.py
|
||||
lib/ansible/modules/cloud/amazon/route53_zone.py
|
||||
|
@ -442,7 +441,6 @@ lib/ansible/plugins/lookup/dnstxt.py
|
|||
lib/ansible/plugins/lookup/first_found.py
|
||||
lib/ansible/plugins/lookup/hashi_vault.py
|
||||
lib/ansible/plugins/lookup/mongodb.py
|
||||
lib/ansible/plugins/lookup/sequence.py
|
||||
lib/ansible/plugins/shell/fish.py
|
||||
lib/ansible/plugins/shell/sh.py
|
||||
lib/ansible/plugins/strategy/__init__.py
|
||||
|
|
|
@ -1,12 +1,10 @@
|
|||
E111
|
||||
E114
|
||||
E115
|
||||
E121
|
||||
E122
|
||||
E125
|
||||
E126
|
||||
E129
|
||||
E131
|
||||
E501
|
||||
E712
|
||||
E721
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue