chiark / gitweb /
Only conditionally try to remove completed box
authorCiaran Gultnieks <ciaran@ciarang.com>
Wed, 8 Jan 2014 10:56:53 +0000 (10:56 +0000)
committerCiaran Gultnieks <ciaran@ciarang.com>
Wed, 8 Jan 2014 11:22:30 +0000 (11:22 +0000)
makebuildserver

index 3e81da79f5792f48399aa45aedaa961f47b56742..8235577a07a6c00b1054f4a4f2bc3e8360dddc86 100755 (executable)
@@ -201,5 +201,8 @@ vagrant(['package', '--output', os.path.join('..', boxfile)], serverdir)
 print "Adding box"
 vagrant(['box', 'add', 'buildserver', boxfile, '-f'])
 
-os.remove(boxfile)
+# Remove box file if it exists (older vagrant versions left it there, newer
+# ones seem to delete it
+if os.path.exists(boxfile):
+    os.remove(boxfile)