Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Source Variables

It is possible to access the `name` and `type` of your `source` from
It is possible to access the `name` of your `source` from
provisioners and post-processors:

```hcl
Expand All @@ -23,14 +23,14 @@ build {
sources = ["null.first-example"]

provisioner "shell-local" {
inline = ["echo ${source.name} and ${source.type}"]
inline = ["echo ${source.name}"]
}
}

# This will echo something like:
#
# roles.null.consul: consul and null
# roles.null.nomad: nomad and null
# roles.null.vault: vault and null
# roles.null.first-example: first-example and null
# roles.null.consul: consul
# roles.null.nomad: nomad
# roles.null.vault: vault
# roles.null.first-example: first-example
```