Created
January 12, 2011 22:32
-
-
Save solidsnack/777035 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function hosts_fetch { | |
mkdir -p ./tmp | |
dig heroku.com > ./tmp/dig.list | |
} | |
function hosts { | |
sed -n '/^;; ANSWER SECTION:$/,/^$/ { | |
/^heroku\.com\..*[^.0-9]\([.0-9]*\)$/ { | |
s//\1/ | |
p | |
} | |
}' < ./tmp/dig.list | |
} | |
function trial_run { | |
for host in $(hosts) | |
do | |
echo "## $host" | |
time curl -I -H 'Host: heroku.com' http://$host | |
done | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment