concat variables in to a string

2,976 views
Skip to first unread message

Rimas Mocevicius

unread,
May 30, 2015, 11:11:47 AM5/30/15
to terrafo...@googlegroups.com
Hi there,

Just started to play with a therefrom, so far, so go.
It really makes easier to deploy servers comparing to the bash scripting.

I still have not managed to achieve a few things there.

I have variables set :

variable "static_ip" {
    default = {
      "1" = "10.10.1.1"
      "2" = "10.10.2.1"
      "3" = "10.10.3.1"
    }
}

Using them for servers with count works fine.
But I also need to concat them before the server bootstrap resource
and reuse it later there.

How to concat in the format like this:

etcd(1-3) count needs to be used
for IP using count retrieve it.
 

Any tips/solutions would be very helpful

Thanks a lot

Rimas

Paul Hinze

unread,
May 30, 2015, 6:23:30 PM5/30/15
to terrafo...@googlegroups.com
Hi Rimas!

Since we're talking over on the issue already I'll just link that here in case anybody else comes across this thread first.

https://github.com/hashicorp/terraform/issues/2155

Paul
Reply all
Reply to author
Forward
0 new messages