Node Packaging, Distribution and Installation
Introduction
This page will capture the goals and approach that we will take in distributing the RNode software.
Goals
"Feel" is important: our packages and their installation should "feel normal" for users of a particular platform
On supported Linux Distributions,
They should be installed using the distro-specific package manager and use that package manager's dependency management story.
We should have systemd services for running the node as a daemon.
On macOS,
We should offer novice users a DMG containing a *.app bundle that can be trivially moved into the "Applications" directory like most applications they are familiar.
We should offer more advanced users a self-contained tarball.
Dependency management is a tricky proposition:
it is important for our packages to be self-contained (i.e. have no third-party dependencies that require separate installation).
We should not require a macOS user to install and use any third-party package managers like Homebrew.
Similarly, we should avoid them needing to install a particular version of the JDK/JRE, especially if we are not compatible with recent JDKs.
On Windows
We should offer novice users a self-contained *.exe that can be trivially run from any directory.
We should offer more advanced users a self-contained tarball.
Like macOS, dependency management is a tricky proposition.
It is important for our packages to be self-contained (i.e. have no third-party dependencies that require separate installation).
We should not require a Windows user to install and use any third-party package managers like Choclatey.
Similarly, we should avoid them needing to install a particular version of the JDK/JRE, especially if we are not compatible with recent JDKs.
Package Dependencies
Binary (for execution):
JRE
Java and Scala Libraries (non-native):
Currently managed transparently by sbt (specifically it's ivy-based dependency management subsystem)
These dependencies are automatically copied into our packages by sbt-native-packager during the packaging step.
Native Libraries:
lmdb (currently shipped in a JAR (third-party) and handled like a normal java/scala dependency as above)
libsecp256k1 (currently shipped in a JAR (by us) and handled like a normal java/scala dependency as above)
https://github.com/rchain/secp256k1-java (FFI around -native, this is the JAR we depend on)
libsodium (WIP to ship as JAR: CORE-848)
(Forthcoming fork of kalium to use sodium-native)
Currently no provision to install and use Native Library dependencies from the package manager instead. We might consider changing that.
Supported Platforms for RNode
Platform | Package | Supported Versions | Dependencies | Dependency Management | Goals | Work Items | JRE Licensing |
|---|---|---|---|---|---|---|---|
Linux macOS Windows | Tarball |
| JRE, libsodium | unmanaged. must be installed by user (we do have a shitty script on macOS). | include libsodium packaged as a jar (like lmdb, secp256k1). this allows us to avoid having users need to use homebrew or an alternative package manager. unfortunately, the tarball will always require the end user to have the right JDK or JRE installed. | Addressed by package manager | |
Linux macOS Windows | Docker | Docker | Must be installed by user. |
|
| Addressed by package manager | |
Linux | .rpm |
| JRE, libsodium | handled automatically by yum/dnf | none | Addressed by package manager | |
Linux | .deb |
| JRE, libsodium | handled automatically by apt | none | Addressed by package manager | |
macOS | RNode.app (shipped in RNode.dmg) | macOS 10.12 and up |
| fully self-contained (JRE and libsodium are included in the *.app bundle) | We have not created these packages yet. The idea is to use: https://www.scala-sbt.org/sbt-native-packager/formats/jdkpackager.html
| Open item | |
Windows | RNode.exe (shipped in zip?) | Windows 7 |
| fully self-contained (JRE and libsodium are included in the *.exe bundle) | We have not created these packages yet. The idea is to use: https://www.scala-sbt.org/sbt-native-packager/formats/jdkpackager.html
| Open item |