Resource aws_instance does not have attr private_ip_address (#15890)

This commit is contained in:
Gabriel Francisco 2017-08-23 18:41:16 +02:00 committed by Clint
parent fca841a379
commit 7b3f32f3de
2 changed files with 3 additions and 3 deletions

View File

@ -46,7 +46,7 @@ return list elements by index: `${var.subnets[idx]}`.
#### Attributes of your own resource
The syntax is `self.ATTRIBUTE`. For example `${self.private_ip_address}`
The syntax is `self.ATTRIBUTE`. For example `${self.private_ip}`
will interpolate that resource's private IP address.
-> **Note**: The `self.ATTRIBUTE` syntax is only allowed and valid within

View File

@ -19,7 +19,7 @@ resource "aws_instance" "web" {
# ...
provisioner "local-exec" {
command = "echo ${self.private_ip_address} > file.txt"
command = "echo ${self.private_ip} > file.txt"
}
}
```
@ -114,7 +114,7 @@ resource "aws_instance" "web" {
# ...
provisioner "local-exec" {
command = "echo ${self.private_ip_address} > file.txt"
command = "echo ${self.private_ip} > file.txt"
on_failure = "continue"
}
}