Quick start on “Creating a new docker container”


As a bioinfomatician, one might get into the situation that requires you to run that software in certain environment again and again, unfortunately, on various computers.

The good news is there’s this thing called “Docker”, a container technology that might allow you to do so easier. If you are a fan of “Singularity”, you already know what I’m talking about here.

Without further ado, here’s what you will need:

  1. You’ll need to install Docker on your computer. Also, get a docker hub account. You’ll need this to deposit your docker image.
  2. Get the source code or the pre-compiled software that you want to run
  3. Create a new working directory to store your Dockerfile (see below)
  4. The most important step, which will determine how complicate your life will be authoring a Dockerfile​ is how you choose your base image.
    • Assuming you are trying to run java application, your best bet for the base image would be this image family java:openjdk-8-jre

Consider the following example (stolen from Broad’s Institute tutorial for FireCloud https://software.broadinstitute.org/firecloud/documentation/article?id=9453)

Continue reading Quick start on “Creating a new docker container”

Advertisements

The making of Wunderlist


A quick look wondering around the “About” Section of my favorite to-do list software revealed quite an interesting information about that many license type included in “probably” the making of Wunderlist.

Below are some info from the heading of the license section. I guess this is what make open-source wonderful. The contributors get their credits. Their name continue to live on. Money is not the most important thing in life, although getting pay and also get the credits are always nice.

GNESectionedTableView
Copyright (c) 2014 Gone East LLC. All rights reserved
License: MIT (see below)

PocketSocket
Copyright 2014 Zwopple Limited. All rights reserved.
License: Apache License (see below)

CargoBay
Copyright (c) 2012 Mattt Thompson
License: MIT (see below)

ZipZap
Copyright (c) 2012, Pixelglow Software. All rights reserved.
License: BSD (see below)

Reachability
Copyright (c) 2011-2013, Tony Million. All rights reserved.
License: BSD (see below)

Couchbase-Lite-iOS
Copyright (c) 2014, Couchbase, Inc. All rights reserved.
License: Apache (see below)

OCMock
Copyright (c) 2014, Erik Doernenburg. All rights reserved.
License: Apache (see below)

Lato Free Font
Copyright (c) 2015, Łukasz Dziedzic. All rights reserved.
http://www.latofonts.com/lato-free-fonts/
License: SIL Open Font Licence (see below)

Code from Stackoverflow

window.getSelection return html from Tim Down (link)

Restore Word Document Template Normal.dotm


Sanny wrote on https://superuser.com/questions/1075576/ms-word-for-mac-latest-version-resetting-normal-dotm

From this thread in Apple Exchange, the folder’s location has changed for Office for Mac 2016. It’s now located in

~/Library/Group Containers/UBF8T346G9.Office/User Content/Templates

For Office for Mac 2011 or if you upgraded from this edition to 2016, browse to this location

~/Library/Application Support/Microsoft/Office/User Templates/My Templates

In Windows, I can delete the file normal.dotm to reset it. So you should try doing so in your Mac. You need first to close Word before deleting.

Stop Google Chrome from Opening at Log-in [MacOS]


Normally, if you pinned an app to your “Dock” [the icons at the bottom of the screen], you can simply right-click the app icon and choose > Options > Open at log-in to change this setting.

However, Google Chrome, for some reasons, at the moment, does not have this option checked, but still loaded automatically at log-in.

To disable this, on MacOS Seirra, (also true from Lion on wards), Check the System Preferences > Users & Groups > [your username] > Login Items.

You might see “Google Chrome” in the list of Login Items. By removing it from the list, Chrome should not automatically be loaded anymore.

Bitvise X11 forwarding problem


You may have a problem trying to forward X11 from your Linux server through a terminal in Windows. I use Bitvise as the ssh client as it also provides the interface for sftp to download/upload the files. Not that using command line scp or sftp is not efficient, but in Windows you may have to install those tools separately.

Since I was trying to avoid installing Cygwin initially, Cygwin terminal wasn’t what I initially consider. Therefore, I went ahead and install Bitvise ssh client (instead of putty), which actually turns out to be quite good. The only problem (at least now) is when trying to forward GUI from the server with X11 forwarding, it failed miserably.

  • I’ve tried setting up bitvise in the X11 forward.
  • Installed X11-server from Cygwin (finally T_T).
  • But X11 forwarding still did not work. I got the error message below.

Failed to open channel for X11 forwarding from [::1]:47396 to 127.0.0.1:6000. Error connecting to X11 server: FlowSocketConnector: Failed to connect to target address. Windows error 10061: No connection could be made because the target machine actively refused it.

I kind of have an idea that this is something to do with Windows Firewall, which does not allow a specific port to listen to an incoming connection. But I haven’t quite figured out what to do. It is actually described on the bitvise page, but I guess I haven’t quite read the whole thing.

In short, after install cygwin X11 server, make sure to run the command below to fix the firewall permission. 

C:\cygwin64\bin\XWin -listen tcp -multiwindow

Ref: https://www.bitvise.com/ssh-x11-forwarding

Get a new IP address for a running VirtualBox Ubuntu Machine


Situation

You have started up a virtual machine in VirtualBox. In this case, I ran Ubuntu 16.10. You then realized that the IP address of your VM is not accessible from your local network. Although you can connect from the Host to your Guest VM (Ubuntu).

Therefore, you would like to change the type of network from “NAT” to “Bridge”. You did this through the GUI menu (Machine > Setting > Network > Adapter 1 –> Change to “Bridged Adapter”

OK, now what. You IP addresses is still the same.

You can check your current IP and network device with

ubuntu:~$ ifconfig

Continue reading Get a new IP address for a running VirtualBox Ubuntu Machine

Backing up FreeNAS to Amazon S3


Going through the AWS tutorial about creating File GateWay on my own is not exactly a walk in the park. Although I managed to install awscli and configured the basic requirement, there’s a missing gap that I haven’t quite figured out. This saves me lots of time trying to figure out how I can back up data already live on ZFS FreeNas to AmazonS3.


aws s3 sync /mnt/data/ s3://mybucket

What’s left to figure out next would be how to get all the files out when I need it, and how much it would cost, how to save those cost, etc. For the later part, I guess having AWS free credits does help a lot.

Take a look at the full guide following the link below.

ZFS is excellent at storing all your data safely but “there are still lots of potential ways for your data to die, and you still need to back up your pool. Period. PERIOD!” The process …

Source: Backing up FreeNAS to Amazon S3

Advertisements

Readings between the lines of thoughts