Skip to content

Commit

Permalink
AWS: Restore (erroneously) removed get_instance_private_ip
Browse files Browse the repository at this point in the history
  • Loading branch information
justinsb committed Jul 14, 2015
1 parent c616182 commit 355e922
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions cluster/aws/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,13 @@ function get_instance_public_ip {
--query Reservations[].Instances[].NetworkInterfaces[0].Association.PublicIp
}

function get_instance_private_ip {
local instance_id=$1
$AWS_CMD --output text describe-instances \
--instance-ids ${instance_id} \
--query Reservations[].Instances[].NetworkInterfaces[0].PrivateIpAddress
}

# Gets a security group id, by name ($1)
function get_security_group_id {
local name=$1
Expand Down

0 comments on commit 355e922

Please sign in to comment.