Skip to content

Instantly share code, notes, and snippets.

View pdt256's full-sized avatar

Jamie Isaacs pdt256

View GitHub Profile
@pdt256
pdt256 / gist:2884166
Created June 6, 2012 19:37
Wait for AWS instance and MySQL service to start in Bash
#!/bin/bash
echo -n "Waiting for MySQL to start."
while :; do
ssh 10.0.0.5 "mysql -e 'select @@hostname'" &> /dev/null
[ $? -eq 0 ] && break
echo -n '.'
sleep 5
done