This repository has been archived by the owner on Jul 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 58
/
outputs.tf
43 lines (38 loc) · 1.44 KB
/
outputs.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
output "virtual_machine_names" {
description = "The names of each virtual machine deployed."
value = ["${flatten(list(
vsphere_virtual_machine.virtual_machine_bare.*.name,
vsphere_virtual_machine.virtual_machine_linux.*.name,
vsphere_virtual_machine.virtual_machine_windows.*.name,
))}"]
}
output "virtual_machine_ids" {
description = "The ID of each virtual machine deployed, indexed by name."
value = "${zipmap(
flatten(list(
vsphere_virtual_machine.virtual_machine_bare.*.name,
vsphere_virtual_machine.virtual_machine_linux.*.name,
vsphere_virtual_machine.virtual_machine_windows.*.name,
)),
flatten(list(
vsphere_virtual_machine.virtual_machine_bare.*.id,
vsphere_virtual_machine.virtual_machine_linux.*.id,
vsphere_virtual_machine.virtual_machine_windows.*.id,
)),
)}"
}
output "virtual_machine_default_ips" {
description = "The default IP address of each virtual machine deployed, indexed by name."
value = "${zipmap(
flatten(list(
vsphere_virtual_machine.virtual_machine_bare.*.name,
vsphere_virtual_machine.virtual_machine_linux.*.name,
vsphere_virtual_machine.virtual_machine_windows.*.name,
)),
flatten(list(
vsphere_virtual_machine.virtual_machine_bare.*.default_ip_address,
vsphere_virtual_machine.virtual_machine_linux.*.default_ip_address,
vsphere_virtual_machine.virtual_machine_windows.*.default_ip_address,
)),
)}"
}