Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

A Django web application to make Phylogeny analysis.

Installation requires python 2.7.

To install it:

  • You may first install and activate a new conda environment:
conda create --name ngphylo python=2.7
source activate ngphylo
  • Install all dependencies:
pip install -r requirement.txt
apt-get install redis-server # Ubuntu / Debian
  • Create Django databases
python makemigrations
python migrate
python createcachetable
python collectstatic
  • Create admin user
python createsuperuser
  • Load tool categories (flags)
python loaddata tool_flags
  • Link to a running Galaxy server
python creategalaxyserver --url=http://url_galaxy:port --activate
python addgalaxykey --user <superuser name> --galaxyurl http://url_galaxy:port --galaxykey <galaxy key>
  • Import existing tools from Galaxy to
python importtools --galaxyurl=http://url_galaxy:port \
                             --query="phylogeny" \
                             --flags=toolflags.txt \
  • Two possibilities to link tools inputs and outputs

    1. Already computed links (preferable):
    python import_links --linkfile=toollinks.txt
    1. Links computed on the fly (based on extension compatiblity, deprecated)
    python compute_tools_links --ignore=txt
  • Import Phylogeny workflows from the Galaxy Instance

It will import all workflows with name containing "oneclick" (case insensitive):

python importworkflows --galaxyurl=http://url_galaxy:port --wfnamefile=wfnames.txt
  • Run Celery task queue

    1. Add following lines to NGPhylogeny_fr/settings/
     EMAIL_HOST = 'smtp.server.url'
     EMAIL_PORT = 587
     EMAIL_HOST_USER = 'smtp.user'
     EMAIL_HOST_PASSWORD = 'smtp.pass'
    1. Start celery
     celery multi start 3 -l INFO -c:2 1 -c:3 1 -Q:1 default -Q:2 ncbi_blast -Q:3 monitor --app=NGPhylogeny_fr.celery:app
     celery beat --app=NGPhylogeny_fr.celery:app --loglevel=DEBUG --detach
  • Run the django server

python runserver


You can run via its docker image:

Using a remote galaxy instance:

Note: The remote galaxy instance must contain all necessary tools (listed here).

docker run -p 8080:8000 evolbioinfo/ngphylogeny django_admin_username django_admin_password django_admin_email galaxy_url galaxy_api_key

Using a custom local docker galaxy instance

We provide a galaxy docker image with all tools and workflows already installed (see this github repo):

# Starting Docker image of Galaxy
docker run --privileged=true  \
           -p 8080:80 -p 8121:21 -p 8122:22 \
# MacOS => Starting 
docker run -p 8000:8000 evolbioinfo/ngphylogeny admin admin@admin http://host.docker.internal:8080 admin
# Linux => Starting
docker run -p 8000:8000 --net=host evolbioinfo/ngphylogeny admin admin@admin http://localhost:8080 admin

Fully automatic with docker-compose

The docker-compose.yml file in the docker folder is configured to set up a fully automatically running ngphylogeny instance, with 3 services:

  1. A Galaxy server
  2. A PostgreSQL database
  3. The server

First the file must be adapted to specific needs, by changing values between <> with real values, especially:

  • NGPHYLO_HOST : The hostname or ip address of the server on which will be running (for urls purpose)
  • NGPHYLO_EMAIL_HOST: The smtp server for email notification
  • NGPHYLO_EMAIL_PORT: The smtp port
  • NGPHYLO_EMAIL_HOST_USER: The smtp user name
  • NGPHYLO_EMAIL_HOST_PASSWORD: The smtp password
  • NGPHYLO_EMAIL_USE_TLS: True or False, if smtp uses TLS
  • NGPHYLO_DATABASE_NAME: Name of the PostgreSQL database (see below)
  • NGPHYLO_DATABASE_USER: PostgreSQL user name (see below)
  • NGPHYLO_DATABASE_PASSWORD: PostgreSQL password (see below)
  • POSTGRES_USER: PostgreSQL user name (database name is the same)
  • POSTGRES_PASSWORD: PostgreSQL password

Then to run the services:

> docker-compose up -d