Skip to content

dockerFile #26

Open
Open

Description

@portah

How to use dockerFile,
As I understand it works with dockerImageId, both of them has to be specified!

It would be nice to try it in some order?

  • dockerImageId
  • dockerPull
  • dockerFile
requirements:
  - "@import": envvar-global.cwl
  - class: InlineJavascriptRequirement
  - class: DockerRequirement
    dockerImageId: scidap/star:v2.5.0a
    dockerPull: scidap/star:v2.5.0a
    dockerFile: |
      #################################################################
      # Dockerfile
      #
      # Software:         STAR
      # Software Version: 2.5.0a
      # Description:      STAR image for SciDAP
      # Website:          https://github.com/alexdobin/STAR, http://scidap.com/
      # Provides:         STAR
      # Base Image:       scidap/scidap:v0.0.1
      # Build Cmd:        docker build --rm -t scidap/star:v2.5.0a .
      # Pull Cmd:         docker pull scidap/star:v2.5.0a
      # Run Cmd:          docker run --rm scidap/star:v2.5.0a STAR
      #################################################################

      ### Base Image
      FROM scidap/scidap:v0.0.1
      MAINTAINER Andrey V Kartashov "[email protected]"
      ENV DEBIAN_FRONTEND noninteractive

      ################## BEGIN INSTALLATION ######################

      WORKDIR /tmp

      ### Install STAR

      ENV VERSION 2.5.0a
      ENV NAME STAR
      ENV URL "https://github.com/alexdobin/STAR/archive/${NAME}_${VERSION}.tar.gz"

      RUN wget -q -O - $URL | tar -zxv && \
      cd ${NAME}-${NAME}_${VERSION}/source && \
      make -j 4 && \
      cd .. && \
      cp ./bin/Linux_x86_64_static/STAR /usr/local/bin/ && \
      cd .. && \
      strip /usr/local/bin/${NAME}; true && \
      rm -rf ./${NAME}-${NAME}_${VERSION}/
/usr/local/bin/cwltool 1.0.20151126171959
Got workflow error
Traceback (most recent call last):
  File "build/bdist.macosx-10.11-intel/egg/cwltool/main.py", line 159, in single_job_executor
    r.run(**kwargs)
  File "build/bdist.macosx-10.11-intel/egg/cwltool/job.py", line 56, in run
    img_id = docker.get_from_requirements(docker_req, docker_is_req, pull_image)
  File "build/bdist.macosx-10.11-intel/egg/cwltool/docker.py", line 95, in get_from_requirements
    if get_image(r, pull_image, dry_run):
  File "build/bdist.macosx-10.11-intel/egg/cwltool/docker.py", line 21, in get_image
    sp = dockerRequirement["dockerImageId"].split(":")
KeyError: 'dockerImageId'
Workflow error:
  'dockerImageId'

Activity

  1. manu-chroma commented on Jul 18, 2017

    @manu-chroma
    Member

    Hey @portah, it's been a very long time but can you confirm if you're still facing this problem? 😅

  2. manu-chroma commented on Aug 15, 2017

    @manu-chroma
    Member

    cwlVersion is not specified in the workflow. I added cwlversion: v1.0 and tried running to get the following errror:

    (venv) [venv] ~/github/test_cwl_runner $ cwl-runner test.cwl                                                  21:57:14
    /home/manu/github/cwltool/venv/bin/cwl-runner 1.0.20170812174804
    Resolved 'test.cwl' to 'file:///home/manu/github/test_cwl_runner/test.cwl'
    Tool definition failed validation:
    test.cwl:1:1: Object `test.cwl` is not valid because
                    - tried `CommandLineTool` but
                        Missing 'class' field
                    - tried `ExpressionTool` but
                        Missing 'class' field
                    - tried `Workflow` but
                        Missing 'class' field
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions