echo"$(date-u) - waiting for torbrowser to start."
echo"$(date-u) - waiting for torbrowser to start."
# allow up to 60 seconds for torbrowser to start
# allow up to 63 seconds for torbrowser to start
for i in$(seq 1 6);do
for i in$(seq 1 7);do
sleep 10
sleep 5 ;sleep$i
# this directory only exists once torbrower has successfully started
# this directory only exists once torbrower has successfully started
# (and pattern matching doesnt work because of schroot…)
# (and pattern matching doesnt work because of schroot…)
local BROWSER_PROFILE=TorBrowser/Data/Browser/profile.default
local BROWSER_PROFILE=TorBrowser/Data/Browser/profile.default
...
@@ -242,8 +243,9 @@ download_and_launch() {
...
@@ -242,8 +243,9 @@ download_and_launch() {
xvkbd -text"\r"> /dev/null 2>&1
xvkbd -text"\r"> /dev/null 2>&1
sleep 3
sleep 3
update_screenshot
update_screenshot
for i in$(seq 1 6);do
# allow up to 63 seconds for torbrowser to make the first connection through tor
sleep 10
for i in$(seq 1 7);do
sleep 5 ;sleep$i
update_screenshot
update_screenshot
TOR_RUNNING=$(gocr $WORKSPACE/screenshot.png 2>/dev/null | egrep "(Search securely|Tor Is NOT all you need to browse|There are many ways you can help)"||true)
TOR_RUNNING=$(gocr $WORKSPACE/screenshot.png 2>/dev/null | egrep "(Search securely|Tor Is NOT all you need to browse|There are many ways you can help)"||true)