Browse code

only run apt-get install if needed - fixes multiple builds being kicked off at once

Jesse Andrews authored on 2011/10/25 09:06:58
Showing 1 changed files
... ...
@@ -101,8 +101,8 @@ function kill_unmount() {
101 101
     exit 1
102 102
 }
103 103
 
104
-# Install deps
105
-apt-get install -y --force-yes kvm libvirt-bin kpartx
104
+# Install deps if needed
105
+dpkg -l kvm libvirt-bin kpartx || apt-get install -y --force-yes kvm libvirt-bin kpartx
106 106
 
107 107
 # Let Ctrl-c kill tail and exit
108 108
 trap kill_unmount SIGINT