Docker Installation - giffordlabcvr/Flu-GLUE GitHub Wiki

How Docker-Based GLUE Works

GLUE is packaged into two Docker images:

  • cvrbioinformatics/gluetools-mysql: Provides the MySQL database backend for GLUE, including scripts to manage datasets. This container runs in the background and offers persistent data storage.

  • cvrbioinformatics/gluetools: Contains the GLUE engine, supporting tools (e.g., MAFFT, RAxML), and an interactive shell for running GLUE commands.


Steps to Install Docker-Based Flu-GLUE

1. Install Docker

Ensure Docker is installed on your system. Follow the instructions here:
🔗 Install Docker


2. Set Up the gluetools-mysql Container

Pull the database image:

docker pull cvrbioinformatics/gluetools-mysql:latest

Start a container running in the background:

docker run --detach --name gluetools-mysql cvrbioinformatics/gluetools-mysql:latest

â„šī¸ The gluetools-mysql container provides persistent storage for GLUE projects and runs as a daemon.


3. Install the Flu-GLUE Project

Load the Flu-GLUE dataset into the running database container:

docker exec gluetools-mysql installGlueProject.sh flu_glue

This installs the latest Flu-GLUE database from GitHub:

https://github.com/giffordlabcvr/Flu-GLUE/raw/refs/heads/main/flu_glue.sql.gz

4. Start a GLUE Shell Session

Pull the interactive shell image:

docker pull cvrbioinformatics/gluetools:latest

Run the GLUE shell, linked to the database container:

docker run --rm -it --name gluetools --link gluetools-mysql cvrbioinformatics/gluetools:latest

You should enter the GLUE interactive console:

GLUE Version 1.1.113
...
GLUE>

List installed projects:

GLUE> list project

Expected output:

+===========+==========================================+
| name      | description                              |
+===========+==========================================+
| flu       | Core GLUE project for influenza viruses  |
+===========+==========================================+
Projects found: 1


Hints & Tips for Using Docker-Based GLUE

Adjusting Console Log Level

To reduce verbosity in the shell:

GLUE> console set log-level INFO

Using a Custom Working Directory

Override the default working directory using --workdir. Example:

docker run --rm -it --name gluetools \
  --volume /path/to/flu:/opt/flu \
  --workdir /opt/flu \
  --link gluetools-mysql \
  cvrbioinformatics/gluetools:latest

This sets your GLUE session to operate within /opt/flu.


Using Host Preferences and History

To use .gluerc and .glue_history from your host system:

--volume /home/username:/home/username

This ensures command history and preferences persist between sessions.


Restarting After Reboot

If your computer restarts, the container will stop. To restart it:

docker start gluetools-mysql

âš ī¸ This only works if the container still exists. If you remove it with docker rm, all stored data will be lost.