1
0
Fork 0
mirror of https://github.com/MillironX/nf-configs.git synced 2024-11-22 16:29:55 +00:00
nf-configs/README.md

127 lines
7.8 KiB
Markdown
Raw Normal View History

2019-11-26 14:45:33 +00:00
# [![nf-core/configs](docs/images/nfcore-configs_logo.png "nf-core/configs")](https://github.com/nf-core/configs)
2018-11-27 09:17:55 +00:00
2019-11-26 14:45:33 +00:00
[![Lint Status](https://github.com/nf-core/configs/workflows/Configs%20tests/badge.svg)](https://github.com/nf-core/configs/workflows/Configs%20tests/badge.svg)
2018-11-27 09:17:55 +00:00
A repository for hosting nextflow config files containing custom parameters required to run nf-core pipelines at different Institutions.
## Table of contents
2019-11-25 23:25:49 +00:00
2019-11-26 14:45:33 +00:00
* [Table of contents](#table-of-contents)
* [Using an existing config](#using-an-existing-config)
* [Configuration and parameters](#configuration-and-parameters)
* [Offline usage](#offline-usage)
* [Adding a new config](#adding-a-new-config)
* [Checking user hostnames](#checking-user-hostnames)
* [Testing](#testing)
* [Documentation](#documentation)
* [Uploading to `nf-core/configs`](#uploading-to-nf-coreconfigs)
* [Help](#help)
2018-11-27 09:17:55 +00:00
2018-11-29 17:41:54 +00:00
## Using an existing config
2018-11-27 09:17:55 +00:00
2019-11-19 15:36:51 +00:00
The Nextflow [`-c`](https://www.nextflow.io/docs/latest/config.html) parameter can be used with nf-core pipelines in order to load custom config files that you have available locally. However, if you or other people within your organisation are likely to be running nf-core pipelines regularly it may be a good idea to use/create a custom config file that defines some generic settings unique to the computing environment within your organisation.
2018-11-27 09:17:55 +00:00
2018-11-29 17:41:54 +00:00
### Configuration and parameters
2018-11-27 09:17:55 +00:00
2018-11-29 17:49:03 +00:00
The config files hosted in this repository define a set of parameters which are specific to compute environments at different Institutions but generic enough to be used with all nf-core pipelines.
2018-11-29 15:26:08 +00:00
2019-10-10 13:33:06 +00:00
All nf-core pipelines inherit the functionality provided by Nextflow, and as such custom config files can contain parameters/definitions that are available to both. For example, if you have the ability to use [Singularity](https://singularity.lbl.gov/) on your HPC you can add and customize the Nextflow [`singularity`](https://www.nextflow.io/docs/latest/config.html#scope-singularity) scope in your config file. Similarly, you can define a Nextflow [`executor`](https://www.nextflow.io/docs/latest/executor.html) depending on the job submission process available on your cluster. In contrast, the `params` section in your custom config file will typically define parameters that are specific to nf-core pipelines.
2018-11-29 17:41:54 +00:00
2019-11-19 15:36:51 +00:00
You should be able to get a good idea as to how other people are customising the execution of their nf-core pipelines by looking at some of the config files in [`nf-core/configs`](https://github.com/nf-core/configs/tree/master/conf).
2018-11-29 15:26:08 +00:00
### Offline usage
If you want to use an existing config available in `nf-core/configs`, and you're running on a system that has no internet connection, you'll need to download the config file and place it in a location that is visible to the file system on which you are running the pipeline. Then run the pipeline with `--custom_config_base`
or `params.custom_config_base` set to the location of the directory containing the repository files:
```bash
2019-03-05 15:53:59 +00:00
## Download and unzip the config files
cd /path/to/my/configs
wget https://github.com/nf-core/configs/archive/master.zip
unzip master.zip
## Run the pipeline
cd /path/to/my/data
nextflow run /path/to/pipeline/ --custom_config_base /path/to/my/configs/configs-master/
```
Alternatively, instead of using the configuration profiles from this repository, you can run your
pipeline directly calling the single institutional config file that you need with the `-c` parameter.
```bash
2019-03-05 15:28:10 +00:00
nextflow run /path/to/pipeline/ -c /path/to/my/configs/configs-master/conf/my_config.config
```
2019-03-05 15:28:10 +00:00
> Note that the nf-core/tools helper package has a `download` command to download all required pipeline
> files + singularity containers + institutional configs in one go for you, to make this process easier.
2018-11-29 15:26:08 +00:00
## Adding a new config
2018-11-29 17:49:03 +00:00
If you decide to upload your custom config file to `nf-core/configs` then this will ensure that your custom config file will be automatically downloaded, and available at run-time to all nf-core pipelines, and to everyone within your organisation. You will simply have to specify `-profile <config_name>` in the command used to run the pipeline. See [`nf-core/configs`](https://github.com/nf-core/configs/tree/master/conf) for examples.
2018-11-29 17:41:54 +00:00
Please also make sure to add an extra `params` section with `params.config_profile_description`, `params.config_profile_contact` and `params.config_profile_url` set to reasonable values. Users will get information on who wrote the configuration profile then when executing a nf-core pipeline and can report back if there are things missing for example.
## Checking user hostnames
If your cluster has a set of consistent hostnames, nf-core pipelines can check that users are using your profile.
Add one or more hostname substrings to `params.hostnames` under a key that matches the profile name.
If the user's hostname contains this string at the start of a run or when a run fails and their profile
does not contain the profile name, a warning message will be printed.
2018-11-29 15:26:08 +00:00
### Testing
2018-11-27 09:17:55 +00:00
2019-01-04 15:39:02 +00:00
If you want to add a new custom config file to `nf-core/configs` please test that your pipeline of choice runs as expected by using the [`-c`](https://www.nextflow.io/docs/latest/config.html) parameter.
2018-11-27 09:17:55 +00:00
```bash
## Example command for nf-core/rnaseq
nextflow run nf-core/rnaseq --reads '*_R{1,2}.fastq.gz' --genome GRCh37 -c '[path to custom config]'
2018-11-27 09:17:55 +00:00
```
2018-11-29 15:26:08 +00:00
### Documentation
You will have to create a [Markdown document](https://www.markdownguide.org/getting-started/) outlining the details required to use the custom config file within your organisation. You might orientate yourself using the [Template](docs/template.md) that we provide and filling out the information for your cluster there.
2018-11-29 12:20:25 +00:00
See [`nf-core/configs/docs`](https://github.com/nf-core/configs/tree/master/docs) for examples.
2019-10-10 13:33:06 +00:00
Currently documentation is available for the following systems:
2019-10-10 13:33:06 +00:00
* [AWSBATCH](docs/awsbatch.md)
* [BIGPURPLE](docs/bigpurple.md)
2019-07-31 20:52:16 +00:00
* [BINAC](docs/binac.md)
2019-09-22 14:45:09 +00:00
* [CBE](docs/cbe.md)
* [CCGA](docs/ccga.md)
* [CCGA_DX](/docs/ccga_dx.md)
* [CFC](docs/binac.md)
* [CRICK](docs/crick.md)
2019-07-31 20:52:16 +00:00
* [CZBIOHUB_AWS](docs/czbiohub.md)
* [CZBIOHUB_AWS_HIGHPRIORITY](docs/czbiohub.md)
2019-11-11 11:28:45 +00:00
* [DENBI_QBIC](docs/denbi_qbic.md)
2019-11-25 15:37:00 +00:00
* [GENOTOUL](docs/genotoul.md)
2019-10-16 16:15:04 +00:00
* [GENOUEST](docs/genouest.md)
* [GIS](docs/gis.md)
* [HEBBE](docs/hebbe.md)
2019-08-05 12:59:36 +00:00
* [KRAKEN](docs/kraken.md)
2019-01-10 14:46:16 +00:00
* [MUNIN](docs/munin.md)
2019-07-31 20:52:16 +00:00
* [PASTEUR](docs/pasteur.md)
* [PHOENIX](docs/phoenix.md)
* [PRINCE](docs/prince.md)
* [SHH](docs/shh.md)
* [UCT_HEX](docs/uct_hex.md)
* [UPPMAX](docs/uppmax.md)
2019-07-31 21:09:30 +00:00
* [UPPMAX_DEVEL](docs/uppmax.md)
* [UZH](docs/uzh.md)
2018-11-29 15:26:08 +00:00
### Uploading to `nf-core/configs`
2018-11-29 12:20:25 +00:00
[Fork](https://help.github.com/articles/fork-a-repo/) the `nf-core/configs` repository to your own GitHub account. Within the local clone of your fork add the custom config file to the [`conf/`](https://github.com/nf-core/configs/tree/master/conf) directory, and the documentation file to the [`docs/`](https://github.com/nf-core/configs/tree/master/docs) directory. You will also need to edit and add your custom profile to the [`nfcore_custom.config`](https://github.com/nf-core/configs/blob/master/nfcore_custom.config) file in the top-level directory of the clone.
2018-11-27 09:17:55 +00:00
2019-11-26 14:12:42 +00:00
Afterwards, make sure to edit the `.github/main.yml` file and add your profile name to the alphabetically sorted `profile:` scope. This way, it will be tested automatically using GitHub Actions. If you forget to do this, tests will fail and complain about that.
2019-11-25 23:25:49 +00:00
2018-11-29 12:20:25 +00:00
Commit and push these changes to your local clone on GitHub, and then [create a pull request](https://help.github.com/articles/creating-a-pull-request-from-a-fork/) on the `nf-core/configs` GitHub repo with the appropriate information.
2018-11-27 09:17:55 +00:00
2018-11-29 17:49:03 +00:00
We will be notified automatically when you have created your pull request, and providing that everything adheres to nf-core guidelines we will endeavour to approve your pull request as soon as possible.
2018-11-27 09:17:55 +00:00
2018-11-29 14:54:20 +00:00
## Help
2019-07-31 20:52:16 +00:00
If you have any questions or issues please send us a message on [Slack](https://nf-co.re/join/slack).