mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
@@ -297,7 +297,7 @@ def main():
|
||||
|
||||
# First check if we were given a dhcp_options_id
|
||||
if not params['dhcp_options_id']:
|
||||
# No, so create new_options from the parameters
|
||||
# No, so create new_options from the parameters
|
||||
if params['dns_servers'] is not None:
|
||||
new_options['domain-name-servers'] = params['dns_servers']
|
||||
if params['netbios_name_servers'] is not None:
|
||||
|
||||
@@ -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()
|
||||
|
||||
@@ -314,8 +314,8 @@ def main():
|
||||
results['task']=existing
|
||||
else:
|
||||
if not module.check_mode:
|
||||
# it exists, so we should delete it and mark changed.
|
||||
# return info about the cluster deleted
|
||||
# it exists, so we should delete it and mark changed.
|
||||
# return info about the cluster deleted
|
||||
results['task'] = service_mgr.stop_task(
|
||||
module.params['cluster'],
|
||||
module.params['task']
|
||||
|
||||
@@ -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':
|
||||
@@ -158,17 +158,17 @@ def main():
|
||||
new_group = conn.create_cluster_subnet_group(group_name, group_description, group_subnets)
|
||||
group = {
|
||||
'name': new_group['CreateClusterSubnetGroupResponse']['CreateClusterSubnetGroupResult']
|
||||
['ClusterSubnetGroup']['ClusterSubnetGroupName'],
|
||||
['ClusterSubnetGroup']['ClusterSubnetGroupName'],
|
||||
'vpc_id': new_group['CreateClusterSubnetGroupResponse']['CreateClusterSubnetGroupResult']
|
||||
['ClusterSubnetGroup']['VpcId'],
|
||||
['ClusterSubnetGroup']['VpcId'],
|
||||
}
|
||||
else:
|
||||
changed_group = conn.modify_cluster_subnet_group(group_name, group_subnets, description=group_description)
|
||||
group = {
|
||||
'name': changed_group['ModifyClusterSubnetGroupResponse']['ModifyClusterSubnetGroupResult']
|
||||
['ClusterSubnetGroup']['ClusterSubnetGroupName'],
|
||||
['ClusterSubnetGroup']['ClusterSubnetGroupName'],
|
||||
'vpc_id': changed_group['ModifyClusterSubnetGroupResponse']['ModifyClusterSubnetGroupResult']
|
||||
['ClusterSubnetGroup']['VpcId'],
|
||||
['ClusterSubnetGroup']['VpcId'],
|
||||
}
|
||||
|
||||
changed = True
|
||||
|
||||
@@ -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)
|
||||
|
||||
Reference in New Issue
Block a user