From f11a3d979625ac8d99dea318170ec131fabf0961 Mon Sep 17 00:00:00 2001 From: Pankaj Garg Date: Thu, 28 Mar 2019 15:15:36 -0700 Subject: [PATCH] Fix EC2 scripts for blockstream startup --- net/scripts/ec2-provider.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/net/scripts/ec2-provider.sh b/net/scripts/ec2-provider.sh index 5dac892d28..5bde02d84e 100644 --- a/net/scripts/ec2-provider.sh +++ b/net/scripts/ec2-provider.sh @@ -249,12 +249,14 @@ cloud_CreateInstances() { fi declare instanceId - IFS=: read -r instanceId _ < <(echo "${instances[0]}") + IFS=: read -r instanceId publicIp privateIp zone < <(echo "${instances[0]}") ( set -x # TODO: Poll that the instance has moved to the 'running' state instead of # blindly sleeping for 30 seconds... sleep 30 + declare region= + region=$(__cloud_GetRegion "$zone") aws ec2 associate-address \ --instance-id "$instanceId" \ --region "$region" \