Skip to content

Instantly share code, notes, and snippets.

@mapledyne
Created February 24, 2015 23:20
Show Gist options
  • Save mapledyne/1d7f0420d2eb48256b14 to your computer and use it in GitHub Desktop.
Save mapledyne/1d7f0420d2eb48256b14 to your computer and use it in GitHub Desktop.
Get a Skytap configuration URL from IP address
#!/bin/bash
# A simple script that wraps a call to the Skytap metadata service. This will pull the configuration URL
# from the metadata service. Useful when you have the IP address of the server, but not easy translation to
# what configuration it is.
# It just passes the first parameter into SSH, so use the formatting as apporpriate:
# Example:
# skytap_info [email protected]
ssh ${1} "curl --Silent http://192.168.1.254/skytap | grep -Po 'configuration_url.*?[^,],'" | awk -F'"' {'print $3'}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment