Explain the following block of Terraform code
resource "aws_instance" "some-instance" {
ami = "ami-201720221991yay"
instance_type = "t2.micro
}
Answer
It's a resource of type "aws_instance" used to provision an instance. The name of the resource (NOT INSTANCE) is "some-instance".
The instance itself will be provisioned with type "t2.micro" and using an image of the AMI "ami-201720221991yay".