CyVerse_logo

Home_Icon Learning Center Home

Tool Integration in DE

Tool integration in CyVerse Discovery Environment can be done either for executable tool (includes osg) or interactive tool.

Goal

This 3-step quickstart allows users to integrate the Docker images of their favorite software as executable tool type in DE. If users are interested in integrating the Docker images of their favorite software as osg or interactive, please refer to here and here respectively.

Important

What is executable software/tool?

Any software/tool that can be run on the command line without the need to open any ports


Prerequisites

Downloads, access, and services

In order to complete this tutorial you will need access to the following services/software

Prerequisite Preparation/Notes Link/Download
CyVerse account You will need a CyVerse account to complete this exercise CyVerse User Portal

Platform(s)

We will use the following CyVerse platform(s):

Platform Interface Link Platform Documentation Quick Start
Discovery Environment Web/Point-and-click Discovery Environment DE Manual Discovery Environment Guide

Input and example data

In order to complete this quickstart you will need to have the following inputs prepared

Input File(s) Format Preparation/Notes Example Data
Read1.fastq fastq Make sure it is a fastq file and not fasta file Read1.fastq

Get started

  • Find the Docker image of your tool/software of your interest
  • Test the Docker image with the test data
  • Add tool in CyVerse Discovery Environment
  1. Find the Docker image

We will use fastq-sample for integrating as tool in DE. Fortunately, there is Docker image available for fastq-sample on Dockerhub and so we can use that fastq-sample docker image for integrating that as tool in DE.

Note

If there is no Docker image available for your tool of interest, then you would either find a Dockerfile which you can use to build the Docker image for your tool of interest or create one. You can get more help with either of that from here

  1. Test the Docker image locally on your computer (Optional but recommended)

This is optional but highly recommended step to confirm that the Docker image for your tool of interest is working as expected. Here is how you would test fastq-sample with the intructions they provided in their README

2.1 Pull the image from Dockerhub

$ docker pull upendradevisetty/fastq-sample:0.8

2.2 See the command line help for the image

$ docker run upendradevisetty/fastq-sample:0.8 -h
  fastq-sample [OPTION]... FILE [FILE2]
  Sample random reads from a FASTQ file.Options:
  -n N                    the number of reads to sample (default: 10000)
  -p N                    the proportion of the total reads to sample
  -o, --output=PREFIX     output file prefix
 (Default: "sample")  -c, --complement-output=PREFIX
                          output reads not included in the random sample to
                          a file (or files) with the given prefix (by default,
                          they are not output).
  -r, --with-replacement  sample with replacement
  -s, --seed=SEED         a manual seed to the random number generator
  -h, --help              print this message
  -V, --version           output version information and exit

2.3 Sample run with an example file

$ docker run --rm -v $PWD:/data -w /data upendradevisetty/fastq-sample:0.8 -n 10 Read1.fastq

Once you get the expected output, then you are ready for the next step

  1. Add tool in CyVerse Discovery Environment

Now that the fastq-sample Docker image has been tested, it is now ready to be integrated into DE.

3.1 Log-in to CyVerse Discovery Environment and click on the “Apps” window

3.2 Click “Manage Tools” -> “Tools” -> “Add Tool” and fill the details about your Docker image

add_tool

Procede here to create an app interface in the CyVerse Discovery Environment


Post your question using the intercom button on the bottom right of this page:


Fix or improve this documentation


Home_Icon Learning Center Home