mirror of
https://github.com/kemko/nomad.git
synced 2026-01-01 16:05:42 +03:00
Add tag to instances with OS and add merged output (#25071)
* func: add a new output that merges both windowa and linux clients, but add tags to distinguish them * fix: outputs cant referrence other outputs in terraform * Update e2e/terraform/provision-infra/compute.tf Co-authored-by: Tim Gross <tgross@hashicorp.com> --------- Co-authored-by: Tim Gross <tgross@hashicorp.com>
This commit is contained in:
committed by
GitHub
parent
c5d74a96a3
commit
cfc24116b3
@@ -38,6 +38,7 @@ resource "aws_instance" "client_ubuntu_jammy" {
|
||||
Name = "${local.random_name}-client-ubuntu-jammy-${count.index}"
|
||||
ConsulAutoJoin = "auto-join-${local.random_name}"
|
||||
User = data.aws_caller_identity.current.arn
|
||||
OS = "linux"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,6 +60,7 @@ resource "aws_instance" "client_windows_2016" {
|
||||
Name = "${local.random_name}-client-windows-2016-${count.index}"
|
||||
ConsulAutoJoin = "auto-join-${local.random_name}"
|
||||
User = data.aws_caller_identity.current.arn
|
||||
OS = "windows"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -13,6 +13,10 @@ output "windows_clients" {
|
||||
value = aws_instance.client_windows_2016.*.public_ip
|
||||
}
|
||||
|
||||
output "clients" {
|
||||
value = concat(aws_instance.client_ubuntu_jammy.*.public_ip, aws_instance.client_windows_2016.*.public_ip)
|
||||
}
|
||||
|
||||
output "message" {
|
||||
value = <<EOM
|
||||
Your cluster has been provisioned! To prepare your environment, run:
|
||||
|
||||
Reference in New Issue
Block a user