I am a new to Chef and I am trying to test AWS cluster configuration for 2 db serves + 2 application servers using kitchen-ec2 and facing the following problem:
I cannot dynamically pass ip_address_1 from recipe#1 (recipe#1 for server1 is completed) to recipe#2 (which is config recipe for server2 and is being executed). It would be helpful to hear your advice.
One of the things I can do is to explicitly set IP address in .kitchen.yml for each box I am trying to configure , but I am curious if there is any way I can do it on the fly, smth like Ohai node['ipaddress'] attribute but more generic, maybe a list of all server IP addresses configured in my cluster.
recipe#1 - done - server1 is configured, AWS assigned private ipaddress1
recipe#2 - in progress - server2 configuration is being applied but it requires ipaddress1
Thank you in advance,
Dmitry