Skip to content

Commit

Permalink
Add conda channels in reference docs (#5426)
Browse files Browse the repository at this point in the history

Signed-off-by: Christopher Hakkaart <chris.hakkaart@seqera.io>
Co-authored-by: Paolo Di Tommaso <paolo.ditommaso@gmail.com>
  • Loading branch information
christopher-hakkaart and pditommaso authored Nov 4, 2024
1 parent 2a5f15f commit 549e790
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 12 deletions.
10 changes: 5 additions & 5 deletions docs/conda.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,24 @@ This feature requires the Conda or [Miniconda](https://conda.io/miniconda.html)

Nextflow automatically creates and activates the Conda environment(s) given the dependencies specified by each process.

Dependencies are specified by using the {ref}`process-conda` directive, providing either the names of the required Conda packages, the path of a Conda environment yaml file or the path of an existing Conda environment directory.
Dependencies are specified by using the {ref}`process-conda` directive, providing either the names of the required Conda packages, the path of a Conda environment yaml file, or the path of an existing Conda environment directory.

:::{note}
Conda environments are stored on the file system. By default Nextflow instructs Conda to save the required environments in the pipeline work directory. Therefore the same environment can be created/saved multiple times across multiple executions when using a different work directory.
Conda environments are stored on the file system. By default, Nextflow instructs Conda to save the required environments in the pipeline work directory. The same environment may be created/saved multiple times across multiple executions when using different work directories.
:::

You can specify the directory where the Conda environments are stored using the `conda.cacheDir` configuration property (see the {ref}`configuration page <config-conda>` for details). When using a computing cluster, make sure to use a shared file system path accessible from all compute nodes.
You can specify the directory where the Conda environments are stored using the `conda.cacheDir` configuration property. When using a computing cluster, make sure to use a shared file system path accessible from all compute nodes. See the {ref}`configuration page <config-conda>` for details about Conda configuration.

:::{warning}
The Conda environment feature is not supported by executors that use remote object storage as a work directory e.g. AWS Batch.
The Conda environment feature is not supported by executors that use remote object storage as a work directory. For example, AWS Batch.
:::

### Enabling Conda environment

:::{versionadded} 22.08.0-edge
:::

The use of Conda recipes specified using the {ref}`process-conda` directive needs to be enabled explicitly by setting the option shown below in the pipeline configuration file (i.e. `nextflow.config`):
The use of Conda recipes specified using the {ref}`process-conda` directive needs to be enabled explicitly in the pipeline configuration file (i.e. `nextflow.config`):

```groovy
conda.enabled = true
Expand Down
17 changes: 10 additions & 7 deletions docs/reference/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -472,31 +472,34 @@ Read the {ref}`container-charliecloud` page to learn more about how to use Charl

## `conda`

The `conda` scope controls the creation of a Conda environment by the Conda package manager.
The `conda` scope controls the creation of Conda environments by the Conda package manager.

The following settings are available:

`conda.enabled`
: Enable Conda execution (default: `false`).
: Enables Conda execution (default: `false`).

`conda.cacheDir`
: Defines the path where Conda environments are stored. When using a compute cluster make sure to provide a shared file system path accessible from all compute nodes.
: Defines the path where Conda environments are stored. Ensure the path is accessible from all compute nodes when using a shared file system.

`conda.channels`
: Defines the Conda channels that can be used to resolve Conda packages. Channels can be defined as a list (e.g., `['bioconda','conda-forge']`) or a comma separated list string (e.g., `'bioconda,conda-forge'`). Channel priority decreases from left to right.

`conda.createOptions`
: Defines any extra command line options supported by the `conda create` command. For details see the [Conda documentation](https://docs.conda.io/projects/conda/en/latest/commands/create.html).
: Defines extra command line options supported by the `conda create` command. See the [Conda documentation](https://docs.conda.io/projects/conda/en/latest/commands/create.html) for more information.

`conda.createTimeout`
: Defines the amount of time the Conda environment creation can last. The creation process is terminated when the timeout is exceeded (default: `20 min`).

`conda.useMamba`
: Uses the `mamba` binary instead of `conda` to create the Conda environments. For details see the [Mamba documentation](https://github.com/mamba-org/mamba).
: Uses the `mamba` binary instead of `conda` to create the Conda environments. See the [Mamba documentation](https://github.com/mamba-org/mamba) for more information about Mamba.

`conda.useMicromamba`
: :::{versionadded} 22.05.0-edge
:::
: uses the `micromamba` binary instead of `conda` to create the Conda environments. For details see the [Micromamba documentation](https://mamba.readthedocs.io/en/latest/user_guide/micromamba.html).
: Uses the `micromamba` binary instead of `conda` to create Conda environments. See the [Micromamba documentation](https://mamba.readthedocs.io/en/latest/user_guide/micromamba.html) for more information about Micromamba.

Read the {ref}`conda-page` page to learn more about how to use Conda environments with Nextflow.
See {ref}`conda-page` for more information about using Conda environments with Nextflow.

(config-dag)=

Expand Down

0 comments on commit 549e790

Please sign in to comment.