Skip to content
Snippets Groups Projects

Take Home

You can access the images used in the course via Sciebo: https://uni-duesseldorf.sciebo.de/s/53pA9W9TbOKTgGQ

password provided via e-mail.

All image files referred to below can be found on Sciebo.

We provide three options, in short--

Recommended for Mac, Windows and Linux:

  • Docker - with the user matching inside and outside the container

As during course, not technically recommended, but should work:

  • Docker - with permissive permissions

Recommended for Linux, and in particular HPC's where Singularity is installed:

  • Singularity

Where's Rstudio?

The Rstudio Docker is not mentioned below, as R & Rstudio are probably easier for you to install directly. See:

https://www.r-project.org/

https://www.rstudio.com/products/rstudio/download/

Disclaimer

These instructions have not actually been tested on a large variety of machines. The good thing is most issues will probably become generic Docker and/or Singularity issues that are very google-able. So first thing to do is always search the error message, this will be the fastest help. If it is not enough help, you are welcome to contact us either via e-mail, or better yet by adding an issue to this repository :-)

Docker - with the user matching inside and outside the container

i.e. a better solution for permissions, which didn't work during the course for reasons that are hard to summarize here and probably not relevant on your machine.

  1. Install Docker as appropriate for your machine: https://www.docker.com/
  2. Download pre-built image from course from sciebo rnaseq_docker.tar.gz
  3. Load into Docker: docker image load -i rnaseq_docker.tar.gz
  4. Build a slight modification to the image where the users match
  • navigate to the directory workflows/userdocker, e.g. by using cd on linux
  • run docker build --build-arg USERID=$(id -u) -t rnaseqme --rm ., this should take only a few seconds and ~3GB of hard drive space.
  1. Run for the first time!
  • for instance from the parent directory of where you have rnaseq-workshop downloaded via docker run -it --name rnalive --mount type=bind,source="$(pwd)"/rnaseq-workshop,target=/home/zim-gast/rnaseq-workshop rnaseqme:latest.
  • for your own data / files
    • you will want to make sure they are all to be found (directly or better yet nested) within one directory
    • change the $(pwd)"/rnaseq-workshop of the command above to point to the directory with your files
  • if something goes wrong and you have to e.g. try mounting again, you can remove the container with docker container rm rnalive so that the docker run command can be repeated.
  • if you want to have multiple containers, e.g. to point to separate ARCs for separate projects, you can also replace rnalive in the commands above to a descriptive name for your project.
  1. Resume with docker start -i rnalive

Note: if you did not configure a docker group during install, you may need to preface all commands above with sudo.

Docker - with permissive permissions.

This is what we used during the course, and no, it is still not good practice. But we're including it for completeness, after all, it's familiar. And realistically, if you're on your own machine where no one else, or only trusted colleagues have an account, and considering that we're hardly using Docker to run a public facing web server, the risks could be worse.

Still, do it this way at your own risk. It doesn't take a malicious actor to accidentally delete important files. Have backups (actually always have backups, anyways, and completely regardless of Docker).

  1. Install Docker as appropriate for your machine: https://www.docker.com/
  2. Download pre-built image from course from sciebo rnaseq_docker.tar.gz
  3. Load into Docker: docker image load -i rnaseq_docker.tar.gz
  4. Set permissions on your data directory (here rnaseq-workshop) to be and stay permissive: setfacl --recursive --modify other::rwX,default:other::rwX rnaseq-workshop
  5. Run docker run -it --name rnalive --mount type=bind,source="$(pwd)"/rnaseq-workshop,target=/home/zim-gast/rnaseq-workshop rnaseq:latest
  6. All info on adjusting directories, retrying, resuming, and maybe needing sudo is the same as for the other Docker option above.

Singularity

A container option targeted more at convenience and less at security. (was not available on host machines during the course).

Unfortunately, it is also only actually easy under linux, which is why this is at the bottom of the list. However, it still may be exactly what you want to e.g. work on the HPC or similar.

  1. Install Singularity as appropriate for your machine (including via VM for Windows or Mac): https://docs.sylabs.io/guides/3.0/user-guide/installation.html, note on the HHU HPC (and probably many others) it's already available as a module (all you need to do is module load Singularity).
  2. Download pre-build image from course from sciebo rnaseq-workshop.sif
  3. Run!
  • singularity run rnaseq-workshop.sif, all files within your home directory should be automatically accessible
  • do you need some other directory of files? you can add them with --bind like this singularity run --bind <your_directory>:/mnt/ rnaseq-workshop.sif will make the files available under /mnt/ in the image. For instance, if I was working on the HHU HPC I might want to run singularity run --bind /gpfs/project/alden101/projectA:/mnt/ rnaseq-workshop.sif to mount my folder 'projectA' in my large storage folder on the HPC.
  1. Resuming is the exact same as running.