Skip to content

Option to use Instance Private IPs #8

@neilgroat

Description

@neilgroat

This isn't necessarily an issue but adding a flag or environment variable to choose if the script will collect gru and the minion's private IPs vs public would be useful.

For example, my environment is entirely in Amazon including where lucy would run from. Having the instances within a vpc and security group that is locked down so the systems can only talk to each other and reach the internet allows for better overall security versus opening up port 22 to the entire world, along with the other necessary ports.

I modified the script and rebuilt lucy to give this a try and it worked just fine:

# Step 7 - Get private IP addresses from Gru and Minions
GRU_HOST=$(aws ec2 describe-instances --instance-ids $GRU_INSTANCE_ID \
      --query 'Reservations[*].Instances[*].[PrivateIpAddress]' --output text | tr -d '\n')
echo "Gru at $GRU_HOST"

MINION_HOSTS=$(aws ec2 describe-instances --instance-ids $MINION_INSTANCE_IDS \
      --query 'Reservations[*].Instances[*].[PrivateIpAddress]' --output text | tr '\n' ',')
echo "Minions at at $MINION_HOSTS"

Again not necessarily an issue as the package currently works as is, but would be a nice feature.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions