Scripts to use Equinix Bare Metal API
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
492 B

#!/bin/bash
# eqx-get-project-ssh-config
#
# Give a project name, generate an ~/.ssh/config snippet.
EQXPROJECT="$1"
if [[ $1 == "" ]]
then \
echo -e "Need project name, such as:\n"
eqx-get-project-names
echo
exit
fi
echo
echo "# Add to ~/.clusterssh/clusters"
echo -n "$EQXPROJECT "
# For each Device, get hostname and IP
for EQXDEVICEID in `eqx-get-project-devices-id "$EQXPROJECT"`
do \
echo -n "`eqx-get-deviceid-hostname $EQXDEVICEID` "
done
echo