From c0987b680387ec533c0817e81726e8cd414a1691 Mon Sep 17 00:00:00 2001 From: Ciaran Gultnieks Date: Thu, 9 Jan 2014 21:31:08 +0000 Subject: [PATCH] A scientific solution to issues with vagrant 1.3.5 --- fdroidserver/build.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/fdroidserver/build.py b/fdroidserver/build.py index 03289b19..515b553f 100644 --- a/fdroidserver/build.py +++ b/fdroidserver/build.py @@ -102,6 +102,8 @@ def build_server(app, thisbuild, vcs, build_dir, output_dir, force): if options.verbose: print "...suspending" vagrant(['suspend'], cwd='builder') + print "...waiting a sec..." + time.sleep(10) p = subprocess.Popen(['VBoxManage', 'snapshot', get_builder_vm_id(), 'restore', 'fdroidclean'], cwd='builder', stdout=subprocess.PIPE, stderr=subprocess.STDOUT) output = p.communicate()[0] @@ -112,6 +114,8 @@ def build_server(app, thisbuild, vcs, build_dir, output_dir, force): retcode, output = vagrant(['up'], cwd='builder') if retcode != 0: raise BuildException("Failed to start build server") + print "...waiting a sec..." + time.sleep(10) vm_ok = True else: print "...failed to reset to snapshot" @@ -178,10 +182,14 @@ def build_server(app, thisbuild, vcs, build_dir, output_dir, force): if p.returncode != 0: print output raise BuildException("Failed to take snapshot") + print "...waiting a sec..." + time.sleep(10) print "Restarting new build server" retcode, _ = vagrant(['up'], cwd='builder') if retcode != 0: raise BuildException("Failed to start build server") + print "...waiting a sec..." + time.sleep(10) # Make sure it worked... p = subprocess.Popen(['VBoxManage', 'snapshot', get_builder_vm_id(), 'list', '--details'], cwd='builder', stdout=subprocess.PIPE, stderr=subprocess.STDOUT)