Running nf-core on a laptop
Notes from setting up a standard microbial genomics pipeline on an ordinary Linux laptop, to see where it strains. Results are in benchmarks.
What’s needed
Section titled “What’s needed”- Java 17+ for Nextflow. We pinned Temurin 21 per project with mise:
mise use java@temurin-21. - Nextflow:
curl -s https://get.nextflow.io | bash, then movenextflowonto yourPATH. SettingNXF_HOME=$PWD/.nextflow-homekeeps its cache inside the project. - Docker (or Podman/Apptainer) for the tool containers; your user in the
dockergroup.
Keep the pipeline from taking the whole machine
Section titled “Keep the pipeline from taking the whole machine”A local.config passed with -c local.config:
process.resourceLimits = [cpus: 8, memory: 12.GB, time: 6.h]docker.enabled = trueAdjust to leave room for your desktop: on an 8 GB laptop, memory: 6.GB and cpus: 4.
nextflow run nf-core/bacass -profile test,docker -c local.config --outdir results/bacass-testUse a pipeline’s test profile with --input your_sheet.tsv to try your own sample sheet quickly;
it keeps the profile’s settings that skip large databases. Add -stub-run to check inputs and
wiring without computing anything.
Where it strains
Section titled “Where it strains”- Disk, not RAM or CPU. About 16 GB of container images for one pipeline. Check
docker system dfand prune images you no longer need. - Reference databases. Full Kraken 2 (~80 GB) and GTDB-Tk (~100 GB on disk, ~140 GB RAM) do not
fit a typical laptop. Use the capped Kraken 2 indexes and Bakta’s light database;
dblock plantells you what fits before downloading. - FastQC memory. 2–3 GB per file inside the pipeline;
leanqcdoes the same job in tens of MB.
Gotchas we hit
Section titled “Gotchas we hit”- Pipeline parameters given as bare flags (
--skip_kraken2) arrived as the string"true"and failed schema validation with Nextflow 26.10. Use-params-file params.jsonor the test profile. - With only a sample sheet swapped into the test profile, bacass still asks for Kraken 2 and
Kmerfinder databases unless the profile’s
skip_kraken2/skip_kmerfindersettings are kept.