Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nix package #146

Closed
oneingan opened this issue Dec 3, 2019 · 0 comments
Closed

Nix package #146

oneingan opened this issue Dec 3, 2019 · 0 comments

Comments

@oneingan
Copy link

oneingan commented Dec 3, 2019

This is a Bisq Network proposal. Please familiarize yourself with the submission and review process.

Summary

This is a proposal to package Bisq into Nix package manager, try to merge into upstream nixpkgs repository and embrace Nix as build system.

Motivation

  1. We currently have gradle as build system which is not language agnostic and have different guarantees in terms of reproducible builds. With some scripts here and there.
  2. Side components (bisq-website, bisq-markets, bisq-explorer...) have different stack and guarantees in terms of reproducible builds.
  3. We use javapackager component to create bundle for the application. This component gives us some trouble lately with OpenJDK.
  4. We have not an automated test framework. (Testing Bisq #105)

Why Nix?

Portability

Nix runs on every Linux distribution, macOS and other systems.

Testing framework

NixOS contains infrastructure for building integration tests based on KVM virtual machines. Tests built on this infrastructure are continuously run on new nixpkgs versions to ensure that package continues to install and that various services continue to operate correctly.

Reproducible (#89)

Nix builds packages in isolation from each other. This ensures that they are reproducible and don’t have undeclared dependencies, so if a package works on one machine, it will also work on another.

Integrity

A derivation is a function which takes source code, build tools, and library dependencies, and produces an immutable software package; because Nix is pure (in the functional programming sense), if any of the inputs change, then the result is a different software package.

Development environments

Using the command nix-shell, it can provide development environments containing all tools and libraries necessary to build a project, pinned to defined versions.

Proposal

  • Write a local default.nix in Bisq repository for everyone using standalone Nix package manager.
  • Create a new role: Nixpkgs maintainer.
  • Open a PR in nixpkgs repository for Bisq package with a trusted Bisq maintainer.
  • Write tests using NixOS test framework.
  • Call with developers to understand their development workflows and evaluate Nix as project build system.
  • Call with operators to evaluate NixOps or similar as deployment tool.

References

Projects in the decentralization ecosystem leveraging Nix as build system:

https://github.com/fort-nix/nix-bitcoin
https://github.com/urbit/urbit
https://github.com/holochain/holonix
https://iohk.io/en/blog/posts/2019/02/06/how-we-use-nix-at-iohk/
https://github.com/status-im/status-react/tree/develop/nix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants