2012-10-28 17:48:51 +01:00
|
|
|
#!/bin/bash
|
2012-10-30 22:49:04 +01:00
|
|
|
# download and unzip the sauce connector
|
2012-11-03 18:10:37 +01:00
|
|
|
curl "https://doc-04-2c-docs.googleusercontent.com/docs/securesc/ha0ro937gcuc7l7deffksulhg5h7mbp1/2h0v0tdergb76jsikuo259nptvbvje4o/1351958400000/18059634261225994552/*/0Bx8MZz0WtyeGalRKeG9oRE1nRlk?e=download" | gunzip > /tmp/Sauce-Connect.jar
|
2012-10-30 22:49:04 +01:00
|
|
|
|
|
|
|
# start the sauce connector in background and make sure it doesn't output the secret key
|
2012-11-02 00:46:04 +01:00
|
|
|
(java -jar /tmp/Sauce-Connect.jar $SAUCE_USER $SAUCE_KEY -f /tmp/tunnel > /dev/null )&
|
2012-10-30 22:49:04 +01:00
|
|
|
|
|
|
|
# save the sauce pid in a file
|
|
|
|
echo $! > /tmp/sauce.pid
|
|
|
|
|
|
|
|
# wait for the tunnel to build up
|
|
|
|
while [ ! -e "/tmp/tunnel" ]
|
|
|
|
do
|
|
|
|
sleep 1
|
2012-11-01 22:46:50 +01:00
|
|
|
done
|