printer: mess up input :)
This commit is contained in:
parent
d94e8e9409
commit
94c0e1e8d4
44
printer/testdata/complexhcl.input
vendored
44
printer/testdata/complexhcl.input
vendored
@ -1,42 +1,46 @@
|
|||||||
// This comes from Terraform, as a test
|
// This comes from Terraform, as a test
|
||||||
variable "foo" {
|
variable "foo" {
|
||||||
default = "bar"
|
default = "bar"
|
||||||
description = "bar"
|
description = "bar"
|
||||||
}
|
}
|
||||||
|
|
||||||
provider "aws" {
|
provider "aws" {
|
||||||
access_key = "foo"
|
access_key ="foo"
|
||||||
secret_key = "bar"
|
secret_key = "bar"
|
||||||
}
|
}
|
||||||
|
|
||||||
provider "do" {
|
provider "do" {
|
||||||
api_key = "${var.foo}"
|
api_key = "${var.foo}"
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "aws_security_group" "firewall" {
|
resource "aws_security_group" "firewall" {
|
||||||
count = 5
|
count = 5
|
||||||
}
|
}
|
||||||
|
|
||||||
resource aws_instance "web" {
|
resource aws_instance "web" {
|
||||||
ami = "${var.foo}"
|
ami = "${var.foo}"
|
||||||
security_groups = [
|
security_groups = [
|
||||||
"foo",
|
"foo",
|
||||||
"${aws_security_group.firewall.foo}"
|
"${aws_security_group.firewall.foo}"
|
||||||
]
|
]
|
||||||
|
|
||||||
network_interface {
|
network_interface {
|
||||||
device_index = 0
|
device_index = 0
|
||||||
description = "Main network interface"
|
description = "Main network interface"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
resource "aws_instance" "db" {
|
resource "aws_instance" "db" {
|
||||||
security_groups = "${aws_security_group.firewall.*.id}"
|
security_groups = "${aws_security_group.firewall.*.id}"
|
||||||
VPC = "foo"
|
VPC = "foo"
|
||||||
|
|
||||||
depends_on = ["aws_instance.web"]
|
depends_on = ["aws_instance.web"]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
output "web_ip" {
|
output "web_ip" {
|
||||||
value = "${aws_instance.web.private_ip}"
|
|
||||||
|
value="${aws_instance.web.private_ip}"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user