20259: Add documentation for banner and tooltip features
[arvados.git] / sdk / dev-jobs.dockerfile
1 # Copyright (C) The Arvados Authors. All rights reserved.
2 #
3 # SPDX-License-Identifier: Apache-2.0
4
5 # Dockerfile for building an arvados/jobs Docker image from local git tree.
6 #
7 # Intended for use by developers working on arvados-python-client or
8 # arvados-cwl-runner and need to run a crunch job with a custom package
9 # version.
10 #
11 # Use arvados/build/build-dev-docker-jobs-image.sh to build.
12 #
13 # (This dockerfile file must be located in the arvados/sdk/ directory because
14 #  of the docker build root.)
15
16 FROM debian:buster-slim
17 MAINTAINER Arvados Package Maintainers <packaging@arvados.org>
18
19 ENV DEBIAN_FRONTEND noninteractive
20
21 ARG pythoncmd=python3
22 ARG pipcmd=pip3
23
24 RUN apt-get update -q && apt-get install -qy --no-install-recommends \
25     git ${pythoncmd}-pip ${pythoncmd}-virtualenv ${pythoncmd}-dev libcurl4-gnutls-dev \
26     libgnutls28-dev nodejs ${pythoncmd}-pyasn1-modules build-essential ${pythoncmd}-setuptools
27
28 ARG sdk
29 ARG runner
30 ARG salad
31 ARG cwlutils
32 ARG cwltool
33
34 ADD python/dist/$sdk /tmp/
35 ADD cwl/salad_dist/$salad /tmp/
36 ADD cwl/cwltool_dist/$cwltool /tmp/
37 ADD cwl/cwlutils_dist/$cwlutils /tmp/
38 ADD cwl/dist/$runner /tmp/
39
40 RUN $pipcmd install wheel
41 RUN cd /tmp/arvados-python-client-* && $pipcmd install .
42 RUN if test -d /tmp/schema-salad-* ; then cd /tmp/schema-salad-* && $pipcmd install . ; fi
43 RUN if test -d /tmp/cwl-utils-* ; then cd /tmp/cwl-utils-* && $pipcmd install . ; fi
44 RUN if test -d /tmp/cwltool-* ; then cd /tmp/cwltool-* && $pipcmd install . ; fi
45 RUN cd /tmp/arvados-cwl-runner-* && $pipcmd install .
46
47 # Sometimes Python dependencies install successfully but don't
48 # actually work.  So run arvados-cwl-runner here to catch fun
49 # dependency errors like pkg_resources.DistributionNotFound.
50 RUN arvados-cwl-runner --version
51
52 # Install dependencies and set up system.
53 RUN /usr/sbin/adduser --disabled-password \
54       --gecos 'Crunch execution user' crunch && \
55     /usr/bin/install --directory --owner=crunch --group=crunch --mode=0700 /keep /tmp/crunch-src /tmp/crunch-job
56
57 USER crunch