Skip to content

Commit

Permalink
Update ec2_instance.py (#652) (#653)
Browse files Browse the repository at this point in the history
[PR #652/4e9aec79 backport][stable-2] Update ec2_instance.py

This is a backport of PR #652 as merged into main (4e9aec7).
SUMMARY
vpc_subnet_id is not configurable under the network key, just tried a copy of the example and got this error->
TASK [manage_ec2_instances : Create EC2 instances for ansible node (control node)] **********************************************************************************************************
fatal: [localhost]: FAILED! => changed=false
  msg: No default subnet could be found - you must include a VPC subnet ID (vpc_subnet_id parameter) to create an instance

changing to match other examples
ISSUE TYPE

Docs Pull Request

COMPONENT NAME
ec2_instance
ADDITIONAL INFORMATION
n/a, only see one bad example here
  • Loading branch information
patchback[bot] authored Feb 9, 2022
1 parent 7832dc8 commit a1959b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/modules/ec2_instance.py
Original file line number Diff line number Diff line change
Expand Up @@ -451,10 +451,10 @@
image_id: ami-123456
exact_count: 5
region: us-east-2
vpc_subnet_id: subnet-0123456
network:
assign_public_ip: yes
security_group: default
vpc_subnet_id: subnet-0123456
tags:
foo: bar
Expand Down

0 comments on commit a1959b8

Please sign in to comment.