nextflow-io / nextflow

A DSL for data-driven computational pipelines
http://nextflow.io
Apache License 2.0
2.75k stars 629 forks source link

Nextflow native package distribution #2028

Open pditommaso opened 3 years ago

pditommaso commented 3 years ago

Summary

Provide a new Nextflow package distribution that runs natively in the target execution environment ie. deb and rpm on Linux and dmg on MacOs.

Goals

Description

The core Nextflow application is distributed as a collection of JAR files that are downloaded by the launcher nextflow script. Managing the download of the required dependencies can create unexpected problems (see #1806), moreover, the need of having a preinstalled Java VM can be overkill for some users.

Recent versions of the Java (16 and later) includes the jpackage tool that allows the creation of a native platform executable including all the application dependencies and the Java runtime. This means that it can be created a self-contained executable that can run natively in the target environment.

See https://openjdk.java.net/jeps/392

pditommaso commented 3 years ago

Example package creation cli

jpackage \
  --type app-image \
  -i build/releases/ \
  -n nextflow \
  --main-class nextflow.cli.Launcher \
  --main-jar nextflow-24.07.0-edge-one.jar
pditommaso commented 1 year ago

Depends on #2951