Skip to content

Commit 786f9e0

Browse files
Merge pull request #72 from rdbartram/feature/disk-output
Output disk uuid
2 parents 99e0efc + 5f615bc commit 786f9e0

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

output.tf

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ output "Windows-uuid" {
2828
value = vsphere_virtual_machine.Windows.*.uuid
2929
}
3030

31+
output "Windows-disks" {
32+
value = { for d in flatten(vsphere_virtual_machine.Windows.*.disk) : d.label => d.uuid }
33+
}
34+
3135
output "Linux-VM" {
3236
description = "VM Names"
3337
value = vsphere_virtual_machine.Linux.*.name
@@ -47,3 +51,7 @@ output "Linux-uuid" {
4751
description = "UUID of the VM in vSphere"
4852
value = vsphere_virtual_machine.Linux.*.uuid
4953
}
54+
55+
output "Linux-disks" {
56+
value = { for d in flatten(vsphere_virtual_machine.Linux.*.disk) : d.label => d.uuid }
57+
}

0 commit comments

Comments
 (0)