-
Notifications
You must be signed in to change notification settings - Fork 41
/
Copy pathoutputs.tf
39 lines (34 loc) · 981 Bytes
/
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
output "public_instances" {
value = local.public_instances
}
output "bastions" {
value = module.configuration.bastions
}
output "public_ip" {
value = {
for key, values in local.public_instances: key => values["public_ip"]
if values["public_ip"] != ""
}
}
output "cluster_name" {
value = lower(var.cluster_name)
}
output "domain" {
value = lower(var.domain)
}
output "accounts" {
value = {
guests = {
usernames = var.nb_users != 0 ? (
"user[${format(format("%%0%dd", length(tostring(var.nb_users))), 1)}-${var.nb_users}]"
) : (
"You have chosen to create user accounts yourself (`nb_users = 0`), please read the documentation on how to manage this at https://github.com/ComputeCanada/magic_castle/blob/main/docs/README.md#103-add-a-user-account"
),
password = module.configuration.guest_passwd
}
sudoer = {
username = var.sudoer_username
password = "N/A (public ssh-key auth)"
}
}
}