Skip to content
This repository has been archived by the owner on Jan 27, 2020. It is now read-only.

Update docs #725

Merged
merged 6 commits into from
Feb 15, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,17 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - `vepCacheVersion` is now defined in `conf/genomes.config` or `conf/igenomes.config`
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - `snpeff` and `vep` containers are now built with conda
- [#716](https://github.com/SciLifeLab/Sarek/pull/716) - Update paths to containers and iGenomes
- [#722](https://github.com/SciLifeLab/Sarek/pull/722) - Update `Sarek-data` submodule
- [#723](https://github.com/SciLifeLab/Sarek/pull/723), [#725](https://github.com/SciLifeLab/Sarek/pull/725) - Update docs
- [#724](https://github.com/SciLifeLab/Sarek/pull/724) - Improved AwsBatch configuration

### `Added`
- [#628](https://github.com/SciLifeLab/Sarek/pull/628), [#722](https://github.com/SciLifeLab/Sarek/pull/722) - `ASCAT` now use `.gc` file
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - Possibility to use cache wen annotating with `snpEff` and `VEP`
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - New `--annotation_cache`, `--snpEff_cache`, `--vep_cache` parameters
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - Helper script to download `snpeff` and `VEP` cache files
- [#719](https://github.com/SciLifeLab/Sarek/pull/719) - Annotation documentation
- [#722](https://github.com/SciLifeLab/Sarek/pull/722) - Add path to ASCAT `.gc` file in `igenomes.config`

### `Removed`
- [#715](https://github.com/SciLifeLab/Sarek/pull/715) - Remove `defReferencesFiles` function from `buildReferences.nf`
Expand All @@ -44,8 +48,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- [#694](https://github.com/SciLifeLab/Sarek/pull/694) - Add monochrome and grey logos for light or dark background
- [#698](https://github.com/SciLifeLab/Sarek/pull/698) - Add btb profile for munin server
- [#702](https://github.com/SciLifeLab/Sarek/pull/702) - Add font-ttf-dejavu-sans-mono `2.37` and fontconfig `2.12.6` to container
- [#722](https://github.com/SciLifeLab/Sarek/pull/722) - Update `Sarek-data` submodule
- [#722](https://github.com/SciLifeLab/Sarek/pull/722) - Add path to ASCAT `.gc` file in `igenomes.config`

### `Changed`

Expand Down
130 changes: 66 additions & 64 deletions docs/CONTAINERS.md
Original file line number Diff line number Diff line change
@@ -1,71 +1,19 @@
# Containers

Subsets of all containers can be downloaded:
Our main container is designed using Bioconda to install most of the tools used in Sarek:
- [sarek](#sarek-)

- For processing, germline variant calling and Reports:
- [sarek](#sarek-)
- For somatic variant calling, add:
- [r-base](#r-base-)
- [runallelecount](#runallelecount-)
- For annotation for GRCh37, you will need:
For annotation, the main container can be used, but the cache has to be downloaded, or additional containers are available with cache (see [annotation guide](ANNOTATION.md)):
- For GRCh37:
- [snpeffgrch37](#snpeffgrch37-)
- [vepgrch37](#vepgrch37-)
- For annotation for GRCh38, you will need:
- For GRCh38:
- [snpeffgrch38](#snpeffgrch38-)
- [vepgrch38](#vepgrch38-)
- For annotation with cache use:
- [sarek](#sarek-)

## Building

Use the Nextflow script to build and/or push containers from Docker and/or Singularity.

All the containers have built in UPPMAX directories, so there is no need to add them for use on UPPMAX clusters.
- See the [Singularity UPPMAX guide](https://www.uppmax.uu.se/support-sv/user-guides/singularity-user-guide/)

### Usage

```bash
nextflow run buildContainers.nf [--docker] [--singularity] /
[--containerPath <path>] [--push] [--containers <container1[,container2..]>] /
[--repository <repository>] [--tag tag]
```

- `--containers`: Choose which containers to build.
Default: `all`.
Possible values (to separate by commas):
- `all` - all available containers.
- `r-base` - the [r-base](#r-base-) container.
- `runallelecount` - the [runallelecount](#runallelecount-) container.
- `sarek` - the [sarek](#sarek-) container.
- `snpeffgrch37` - the [snpeffgrch37](#snpeffgrch37-) container.
- `snpeffgrch38` - the [snpeffgrch38](#snpeffgrch38-) container.
- `vepgrch37` - the [vepgrch37](#vepgrch37-) container.
- `vepgrch38` - the [vepgrch38](#vepgrch38-) container.

- `--docker`: Build containers using `Docker`
- `--push`: Push containers to `DockerHub`
- `--repository`: Build containers under given repository.
Default: `maxulysse`
- `--singularity`: Build containers using `Singularity`.
- `--containerPath`: Select where to download containers.
Default: `$PWD`
- `--tag`: Build containers using given tag.
Default is version number.

### Example

```bash
nextflow run buildContainers.nf --docker --singularity --push --containers sarek
```

### For lazy users
We provide script to build/push or pull all containers
```bash
./scripts/do_all.sh # Build all docker containers
./scripts/do_all.sh --push # Build and push all Docker containers into DockerHub
./scripts/do_all.sh --pull # Pull all containers from DockerHub with Singularity
```
Additional containers need to be downloaded for somatic variant calling with ASCAT:
- [r-base](#r-base-)
- [runallelecount](#runallelecount-)

## What is actually inside the containers

Expand Down Expand Up @@ -103,25 +51,79 @@ We provide script to build/push or pull all containers

- Based on `nfcore/base:latest`
- Contain **[snpEff][snpeff-link]** 4.3.1t
- Contain GRCh37.75
- Contain cache for GRCh37.75

### snpeffgrch38 [![snpeffgrch38-docker status][snpeffgrch38-docker-badge]][snpeffgrch38-docker-link]

- Based on `nfcore/base:latest`
- Contain **[snpEff][snpeff-link]** 4.3.1t
- Contain GRCh38.86
- Contain cache for GRCh38.86

### vepgrch37 [![vepgrch37-docker status][vepgrch37-docker-badge]][vepgrch37-docker-link]

- Based on `nfcore/base:latest`
- Contain **[VEP][vep-link]** 95.1
- Contain GRCh37
- Contain cache for GRCh37 version 95

### vepgrch38 [![vepgrch38-docker status][vepgrch38-docker-badge]][vepgrch38-docker-link]

- Based on `nfcore/base:latest`
- Contain **[VEP][vep-link]** 95.1
- Contain GRCh38
- Contain cache for GRCh38 version 95

## Building

A Nextflow script is provided to build and/or push containers from Docker, or build for Singularity.

### Usage

```bash
nextflow run buildContainers.nf [--docker] [--singularity] /
[--containerPath <path>] [--push] [--containers <container1[,container2..]>] /
[--repository <repository>] [--tag tag]
```

- `--containers`: Choose which containers to build.
Default: `all`.
Possible values (to separate by commas):
- `all` - all available containers.
- `r-base` - the [r-base](#r-base-) container.
- `runallelecount` - the [runallelecount](#runallelecount-) container.
- `sarek` - the [sarek](#sarek-) container.
- `snpeffgrch37` - the [snpeffgrch37](#snpeffgrch37-) container.
- `snpeffgrch38` - the [snpeffgrch38](#snpeffgrch38-) container.
- `vepgrch37` - the [vepgrch37](#vepgrch37-) container.
- `vepgrch38` - the [vepgrch38](#vepgrch38-) container.

- `--docker`: Build containers using `Docker`
- `--push`: Push containers to `DockerHub`
- `--repository`: Build containers under given repository.
Default: `maxulysse`
- `--singularity`: Build containers using `Singularity`.
- `--containerPath`: Select where to download containers.
Default: `$PWD`
- `--tag`: Build containers using given tag.
Default is version number.

### Example

```bash
nextflow run buildContainers.nf --docker --singularity --push --containers sarek
```

### For lazy users
We provide script to build/push or pull all containers
```bash
./scripts/do_all.sh # Build all docker containers
./scripts/do_all.sh --push # Build and push all Docker containers into DockerHub
./scripts/do_all.sh --pull # Pull all containers from DockerHub with Singularity
```

## Building your own
Most of the containers are designed using Bioconda.
The `environment.yml` file can easilly be modified if particular versions of tools are more suited to your needs.
You can then use the building script to build your own containers.
You'll just need to specify the correct repository either in command line or in the configuration files.

[allelecount-link]: https://github.com/cancerit/alleleCount
[bcftools-link]: https://github.com/samtools/bcftools
Expand Down
3 changes: 1 addition & 2 deletions scripts/do_all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,7 @@ function toLower() {

if [[ $TOOL = docker ]] && [[ GRCh37,GRCh38 =~ $GENOME ]]
then
nextflow run buildContainers.nf -profile ${PROFILE} --verbose --docker ${PUSH} --repository ${REPOSITORY} --tag ${TAG} --containers r-base,runallelecount,sarek,snpeff
nextflow run buildContainers.nf -profile ${PROFILE} --verbose --docker ${PUSH} --repository ${REPOSITORY} --tag ${TAG} --containers snpeff$(toLower ${GENOME}),vep$(toLower ${GENOME})
nextflow run buildContainers.nf -profile ${PROFILE} --verbose --docker ${PUSH} --repository ${REPOSITORY} --tag ${TAG} --containers r-base,runallelecount,sarek,snpeff$(toLower ${GENOME}),vep$(toLower ${GENOME})
else
nextflow run buildContainers.nf -profile ${PROFILE} --verbose --singularity --repository ${REPOSITORY} --tag ${TAG} --containerPath containers/ --containers r-base,runallelecount,sarek,snpeff$(toLower ${GENOME}),vep$(toLower ${GENOME})
fi