|
| 1 | +{ |
| 2 | + "version": 1, |
| 3 | + "serial": 1, |
| 4 | + "modules": [ |
| 5 | + { |
| 6 | + "path": [ |
| 7 | + "root" |
| 8 | + ], |
| 9 | + "outputs": {}, |
| 10 | + "resources": { |
| 11 | + "aws_instance.one": { |
| 12 | + "type": "aws_instance", |
| 13 | + "depends_on": [ |
| 14 | + "aws_security_group.example" |
| 15 | + ], |
| 16 | + "primary": { |
| 17 | + "id": "i-aaaaaaaa", |
| 18 | + "attributes": { |
| 19 | + "ami": "ami-XXXXXXXX", |
| 20 | + "availability_zone": "us-east-1b", |
| 21 | + "id": "i-aaaaaaaa", |
| 22 | + "instance_type": "t2.micro", |
| 23 | + "key_name": "", |
| 24 | + "private_dns": "ip-1-1-1-1.ec2.internal", |
| 25 | + "private_ip": "1.1.1.1", |
| 26 | + "public_dns": "", |
| 27 | + "public_ip": "", |
| 28 | + "security_groups.#": "1", |
| 29 | + "security_groups.0": "sg-cccccccc", |
| 30 | + "subnet_id": "subnet-XXXXXXXX", |
| 31 | + "tenancy": "default" |
| 32 | + } |
| 33 | + } |
| 34 | + }, |
| 35 | + "aws_instance.two": { |
| 36 | + "type": "aws_instance", |
| 37 | + "depends_on": [ |
| 38 | + "aws_security_group.example" |
| 39 | + ], |
| 40 | + "primary": { |
| 41 | + "id": "i-bbbbbbbb", |
| 42 | + "attributes": { |
| 43 | + "ami": "ami-XXXXXXXX", |
| 44 | + "availability_zone": "us-east-1b", |
| 45 | + "id": "i-bbbbbbbb", |
| 46 | + "instance_type": "t2.micro", |
| 47 | + "key_name": "", |
| 48 | + "private_dns": "ip-2-2-2-2.ec2.internal", |
| 49 | + "private_ip": "2.2.2.2", |
| 50 | + "public_dns": "", |
| 51 | + "public_ip": "", |
| 52 | + "security_groups.#": "1", |
| 53 | + "security_groups.0": "sg-cccccccc", |
| 54 | + "subnet_id": "subnet-XXXXXXXX", |
| 55 | + "tenancy": "default" |
| 56 | + } |
| 57 | + } |
| 58 | + }, |
| 59 | + "aws_route53_record.example": { |
| 60 | + "type": "aws_route53_record", |
| 61 | + "depends_on": [ |
| 62 | + "aws_instance.one", |
| 63 | + "aws_instance.two" |
| 64 | + ], |
| 65 | + "primary": { |
| 66 | + "id": "XXXXXXXXXXXXXX_something.example.com_CNAME", |
| 67 | + "attributes": { |
| 68 | + "id": "XXXXXXXXXXXXXX_something.example.com_CNAME", |
| 69 | + "name": "something.example.com", |
| 70 | + "records.#": "2", |
| 71 | + "records.0": "i-aaaaaaaa", |
| 72 | + "records.1": "i-bbbbbbbb", |
| 73 | + "ttl": "300", |
| 74 | + "type": "CNAME", |
| 75 | + "zone_id": "XXXXXXXXXXXXXX" |
| 76 | + } |
| 77 | + } |
| 78 | + }, |
| 79 | + "aws_security_group.example": { |
| 80 | + "type": "aws_security_group", |
| 81 | + "primary": { |
| 82 | + "id": "sg-cccccccc", |
| 83 | + "attributes": { |
| 84 | + "description": "Allow SSH and HTTP from inside the firewall", |
| 85 | + "id": "sg-cccccccc", |
| 86 | + "ingress.#": "2", |
| 87 | + "ingress.0.cidr_blocks.#": "2", |
| 88 | + "ingress.0.cidr_blocks.0": "10.0.0.0/8", |
| 89 | + "ingress.0.cidr_blocks.1": "192.168.0.0/16", |
| 90 | + "ingress.0.from_port": "22", |
| 91 | + "ingress.0.protocol": "tcp", |
| 92 | + "ingress.0.security_groups.#": "0", |
| 93 | + "ingress.0.self": "false", |
| 94 | + "ingress.0.to_port": "22", |
| 95 | + "ingress.1.cidr_blocks.#": "2", |
| 96 | + "ingress.1.cidr_blocks.0": "10.0.0.0/8", |
| 97 | + "ingress.1.cidr_blocks.1": "192.168.0.0/16", |
| 98 | + "ingress.1.from_port": "80", |
| 99 | + "ingress.1.protocol": "tcp", |
| 100 | + "ingress.1.security_groups.#": "0", |
| 101 | + "ingress.1.self": "false", |
| 102 | + "ingress.1.to_port": "80", |
| 103 | + "name": "example", |
| 104 | + "owner_id": "111111111111", |
| 105 | + "tags.App": "my_app", |
| 106 | + "tags.Environment": "my_env", |
| 107 | + "vpc_id": "vpc-XXXXXXXX" |
| 108 | + } |
| 109 | + } |
| 110 | + } |
| 111 | + } |
| 112 | + } |
| 113 | + ] |
| 114 | +} |
0 commit comments