From 5646a899f667ee14efc32e9db84c72c0938ac6dc Mon Sep 17 00:00:00 2001 From: Peter Amstutz Date: Wed, 30 Nov 2016 14:25:58 -0500 Subject: [PATCH] 10647: Script + Dockerfile to build arvados/jobs image from local git checkout, for development. --- build/README | 6 +++- build/build-dev-docker-jobs-image.sh | 51 ++++++++++++++++++++++++++++ sdk/dev-jobs.dockerfile | 38 +++++++++++++++++++++ 3 files changed, 94 insertions(+), 1 deletion(-) create mode 100755 build/build-dev-docker-jobs-image.sh create mode 100644 sdk/dev-jobs.dockerfile diff --git a/build/README b/build/README index 418254457d..4c67839a10 100644 --- a/build/README +++ b/build/README @@ -23,7 +23,11 @@ run-build-packages-python-and-ruby.sh Build Python and Ruby packages suitable run-build-docker-images.sh Build arvbox Docker images. -run-build-docker-jobs-image.sh Build arvados/jobs Docker image. +run-build-docker-jobs-image.sh Build arvados/jobs Docker image + (uses published debian packages) + +build-dev-docker-jobs-image.sh Build developer arvados/jobs Docker image + (uses local git tree) run-library.sh A library of functions shared by the various scripts in this diff --git a/build/build-dev-docker-jobs-image.sh b/build/build-dev-docker-jobs-image.sh new file mode 100755 index 0000000000..fb392de234 --- /dev/null +++ b/build/build-dev-docker-jobs-image.sh @@ -0,0 +1,51 @@ +#!/bin/bash + +read -rd "\000" helpmessage < + +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update -q && apt-get install -qy git python-pip python-virtualenv python-dev libcurl4-gnutls-dev libgnutls28-dev nodejs + +RUN pip install -U setuptools + +ARG sdk +ARG runner +ARG cwltool + +ADD python/dist/$sdk /tmp/ +ADD cwl/cwltool_dist/$cwltool /tmp/ +ADD cwl/dist/$runner /tmp/ + +RUN cd /tmp/arvados-python-client-* && python setup.py install +RUN if test -d /tmp/cwltool-* ; then cd /tmp/cwltool-* && python setup.py install ; fi +RUN cd /tmp/arvados-cwl-runner-* && python setup.py install + +# Install dependencies and set up system. +RUN /usr/sbin/adduser --disabled-password \ + --gecos 'Crunch execution user' crunch && \ + /usr/bin/install --directory --owner=crunch --group=crunch --mode=0700 /keep /tmp/crunch-src /tmp/crunch-job + +USER crunch -- 2.30.2