Add build.sh wrapper for build.rb, to make sure Ruby is installed. (Refs #2221)
[arvados.git] / docker / build.sh
old mode 100755 (executable)
new mode 100644 (file)
index b472ff2..9473e01
@@ -1,8 +1,11 @@
-#! /bin/sh
+#! /bin/bash
 
-# build the base wheezy image
-./mkimage-debootstrap.sh arvados/debian wheezy http://debian.lcs.mit.edu/debian/
+# make sure Ruby is installed before proceeding
+if ! ruby -v > /dev/null 2>&1
+then
+    echo "Installing Ruby. You may be required to enter your password."
+    sudo apt-get update
+    sudo apt-get install ruby
+fi
 
-# build the Docker images
-docker build -t arvados/base base
-docker build -t arvados/api api
+./build.rb $*