mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Allow vpc_subnet_id to remain unspecified (see bc0c169)
This commit is contained in:
parent
42fd85f041
commit
650a7365f9
1 changed files with 2 additions and 0 deletions
|
@ -785,6 +785,8 @@ def create_instances(module, ec2, vpc, override_count=None):
|
|||
|
||||
if vpc_subnet_id:
|
||||
vpc_id = vpc.get_all_subnets(subnet_ids=[vpc_subnet_id])[0].vpc_id
|
||||
else:
|
||||
vpc_id = None
|
||||
|
||||
try:
|
||||
# Here we try to lookup the group id from the security group name - if group is set.
|
||||
|
|
Loading…
Reference in a new issue