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.
eqx/eqx-get-deviceid-hostname

21 lines
308 B

#!/bin/bash
# eqx-get-deviceid-hostname
#
# Give a device ID, get hostname
EQXDEVICEID="$1"
if [[ $1 == "" ]]
then \
echo -e "Need device name"
echo
exit
fi
packet \
device get \
--id $EQXDEVICEID | \
grep -v -e '^+' -e "CREATED" | \
cut -f 4 -d " "