Enabling bioinformatics training in a Windows based computer lab with Docker+Dugong

While Linux remains the OS for developers, data scientists and bioinformaticians, uni classrooms remain stubbornly dependent on windows based applications. Yes, on individual PCs you can install Ubuntu command line apps but ask any IT dept about doing this for an entire classroom and you will undoubtedly receive an emphatic "NO".

So how does one do bioinformatics training when students cannot even access the simplest foundation, the OS?

Good question, and none of the potential answers are optimal to be honest. But it's what we need to deal with until Unis realize that open source software is actually good enough to run entire enterprises.

My first thought was to get students to use Putty to log in to a bioinformatics server with SSH. This would be OK, but would be a bit of a headache to manage all the accounts on the server. Also my feeling is that much of the skills learned by the students would be forgotten again as soon as access to the server is revoked.

Therefore, It would be best to introduce students to the Linux GUI desktop to get them familiar with it and perhaps in future they would feel able to install it themselves. I stumbled upon the Dugong project which looks really well suited to this task. Dugong is a bioinformatics friendly OS based on Ubuntu which has a lot of tools preinstalled and installing more tools is really straightforward. It is a docker image, meaning that it is really lightweight, so that one decent server can host dozens of simultaneous GUI sessions. These GUI sessions are easy to join via a web browser when based on the local network. The best part is that it only takes a few commands to get set up once docker is installed.*

# pull the image
docker pull dugong/dugong
# run the image
docker run -d -p 5901:5901 -p 6901:6901 -p 8888:8888 -p 2222:22 --name Dugong -h Dugong -v $HOME/dugong/:$HOME/data/ \
--privileged dugong/dugong
# now connect to the session using a web browser password = vncpassword
firefox http://localhost:6901

This is great for a single session, and only works if the current computer has Docker, but the real benefit is to use Docker to create a bunch of sessions to serve a classroom of students. The following example creates seven identical sessions.

for NUM in `seq -w 07` ; do
  docker run -d -p 59$NUM:5901 -p 69$NUM:6901 \
  --name DugongGUI$NUM -h DugongGUI$NUM \
  -v $HOME/dugong$NUM/:/data/ --privileged dugong/dugong:xfce
done

To join the session, students need to enter the local IP address of the server and port. Note the port

for example http://192.168.0.12:6907/

From this base, students should have control of their linux session including root permission. The only limitation being on access to some hardware like as USB ports. Students will need to access files and data either via SSH or from the web.

* For Ubuntu 18.04 Install Docker from the Official Docker Repository using this guide. Don't install the old version called docker.io





Comments

Popular posts from this blog

Update on the DEE project Dec 2017

Data analysis step 8: Pathway analysis with GSEA

Data analysis step 6: Draw a heatmap from RNA-seq data using R