simply running terraform apply in the single-web-server directory raises:
aws_instance.example: Error launching source instance: VPCResourceNotSpecified: The specified instance type can only be used in a VPC. A subnet ID or network interface ID is required to carry out the request.
status code: 400, request id: 94b7cfbe...
aws_autoscaling_group.example: "tf-asg-20190328160913020900000002": Waiting up to 10m0s: Need at least 2 healthy instances in ASG, have 0. Most recent activity: {
ActivityId: "5cc5a714-61e2-eba7-663b-20124631a347",
AutoScalingGroupName: "tf-asg-20190328160913020900000002",
Cause: "At 2019-03-28T16:18:27Z an instance was started in response to a difference between desired and actual capacity, increasing the capacity from 0 to 2.",
Description: "Launching a new EC2 instance. Status Reason: The requested configuration is currently not supported. Please check the documentation for supported configurations. Launching EC2 instance failed.",
Details: "{"Availability Zone":"us-west-1a"}",
EndTime: 2019-03-28 16:18:29 +0000 UTC,
Progress: 100,
StartTime: 2019-03-28 16:18:29.178 +0000 UTC,
StatusCode: "Failed",
StatusMessage: "The requested configuration is currently not supported. Please check the documentation for supported configurations. Launching EC2 instance failed."
}
Hi,
I'm new to terraform and have been following your guide. I've got the single webserver code running but when I try and run the cluster web servers, I get the following errors. I'm pretty sure I've missed something out!
cluster-of-web-servers]$ terraform plan
Error configuring: 2 error(s) occurred: