Skip to content

Commit

Permalink
Configuring gbrowse-syn
Browse files Browse the repository at this point in the history
  • Loading branch information
bunop committed Nov 14, 2017
1 parent 9a96d8e commit 3fd7d11
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 5 deletions.
35 changes: 35 additions & 0 deletions compose/gbrowse/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,38 @@ $ chown -R www-data.www-data volvox
```

[gbrowse-admin-tutorial]: http://cloud.gmod.org/gbrowse2/tutorial/tutorial.html

Configuring gbrowse_syn
-----------------------

### Create a MySQL database

Connect to a MySQL instance and create `rice_synteny` database:

```
$ docker-compose run --no-deps --rm db mysql -h db -u root --password=my-secret-pw
mysql> CREATE USER gbrowsero IDENTIFIED BY 'gbrowseropass' ;
mysql> CREATE DATABASE rice_synteny ;
mysql> GRANT SELECT ON rice_synteny.* TO gbrowsero@'%';
mysql> exit
```

### Load alignment into database

Launch a gbrowse container:

```
$ docker-compose run --no-deps --rm gbrowse /bin/bash
$ cd /var/lib/gbrowse2/databases/gbrowse_syn/alignments
$ gzip -d rice.aln.gz
$ zcat rice.aln.gz perl | /usr/local/bin/gbrowse_syn_load_alignments_msa.pl -u root -p my-secret-pw --dsn='dbi:mysql:database=rice_synteny;host=db' -f clustalw -v -c -
```

Then reach `gbrowse_syn` from this [link][local-gbrowse_syn]. More information on
`gbrowse_syn` could be found [here][gbrowse_syn] and [here][gbrowse_syn_help]. More information on loading alignments
and `gbrowse_syn` scripts in general could be found [here][gbrowse_syn-script]

[local-gbrowse_syn]: http://localhost:10080/gb2/gbrowse_syn/
[gbrowse_syn]: http://gmod.org/wiki/GBrowse_syn
[gbrowse_syn_help]: http://gmod.org/wiki/GBrowse_syn_Help
[gbrowse_syn-script]: http://gmod.org/wiki/GBrowse_syn_Script
2 changes: 1 addition & 1 deletion compose/gbrowse/gbrowse/conf.d/GBrowse.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

[GENERAL]
config_base = /etc/gbrowse2 # overridden by environment variable GBROWSE_CONF
htdocs_base = /usr/local/apache2/htdocs/gbrowse2
htdocs_base = /var/www/html/gbrowse2
url_base = /gbrowse2
tmp_base = /var/tmp/gbrowse2
persistent_base = /var/lib/gbrowse2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
description = BLASTZ alignments for Oryza sativa

# The synteny database
join = dbi:mysql:database=rice_synteny;host=localhost;user='www-data'
join = dbi:mysql:database=rice_synteny;host=db;user=gbrowsero;password=gbrowseropass

# This option maps the relationship between the species data sources, names and descriptions
# The value for "name" (the first column) is the symbolic name that gbrowse_syn users to identify each species.
Expand All @@ -15,7 +15,7 @@ join = dbi:mysql:database=rice_synteny;host=localhost;user='www-data'
source_map = rice rice_synteny "Domesic Rice (O. sativa)"
wild_rice wild_rice_synteny "Wild Rice"

tmpimages = /var/tmp/gbrowse2
tmpimages = tmp
imagewidth = 800
stylesheet = /gbrowse2/css/gbrowse_transparent.css
cache time = 1
Expand Down
2 changes: 1 addition & 1 deletion compose/gbrowse/gbrowse/conf.d/synteny/rice_synteny.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ db_args = -adaptor memory


# Web site configuration info
tmpimages = /var/tmp/gbrowse2
tmpimages = tmp

[EG]
feature = gene:ensembl
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ db_args = -adaptor memory


# Web site configuration info
tmpimages = /var/tmp/gbrowse2
tmpimages = tmp

################## TRACK CONFIGURATION ####################
# the remainder of the sections configure individual tracks
Expand Down

0 comments on commit 3fd7d11

Please sign in to comment.