aboutsummaryrefslogtreecommitdiff
path: root/pkgs/applications/networking/ipfs-cluster
diff options
context:
space:
mode:
authorJoseph Lukasik <joseph@jgl.me>2018-08-30 14:06:50 -0700
committerJoseph Lukasik <joseph@jgl.me>2018-08-30 14:39:48 -0700
commitaeb360caa3152f32781a5524a393dfc26d3590d9 (patch)
tree61a0dc43d418a22fc67a72399e1f0b4d200437f7 /pkgs/applications/networking/ipfs-cluster
parent94f71d800db2ef7afb9fc8dad9e9aa503bfa2941 (diff)
ipfs-cluster: init at 0.5.0
Diffstat (limited to 'pkgs/applications/networking/ipfs-cluster')
-rw-r--r--pkgs/applications/networking/ipfs-cluster/default.nix39
1 files changed, 39 insertions, 0 deletions
diff --git a/pkgs/applications/networking/ipfs-cluster/default.nix b/pkgs/applications/networking/ipfs-cluster/default.nix
new file mode 100644
index 000000000000..d073593d4880
--- /dev/null
+++ b/pkgs/applications/networking/ipfs-cluster/default.nix
@@ -0,0 +1,39 @@
+{ stdenv, buildGoPackage, fetchFromGitHub, fetchgx, gx-go }:
+
+buildGoPackage rec {
+ name = "ipfs-cluster-${version}";
+ version = "0.5.0";
+ rev = "v${version}";
+
+ goPackagePath = "github.com/ipfs/ipfs-cluster";
+
+ extraSrcPaths = [
+ (fetchgx {
+ inherit name src;
+ sha256 = "0jwz3kd07i5fs0sxds80j8d338skhgxgxra377qxsk0cr2hhj2vm";
+ })
+ ];
+
+ src = fetchFromGitHub {
+ owner = "ipfs";
+ repo = "ipfs-cluster";
+ inherit rev;
+ sha256 = "132whjyplcifq8747hcdrgbc0amhp618dg049jq5nyslcxfgdypm";
+ };
+
+ preBuild = ''
+ # fetchgx stores packages by their ipfs hash
+ # this will rewrite github.com/ imports to gx/ipfs/
+ cd go/src/${goPackagePath}
+ ${gx-go}/bin/gx-go rewrite
+ '';
+
+ meta = with stdenv.lib; {
+ description = "Allocate, replicate, and track Pins across a cluster of IPFS daemons";
+ homepage = https://cluster.ipfs.io/;
+ license = licenses.mit;
+ platforms = platforms.unix;
+ maintainers = with maintainers; [ jglukasik ];
+ };
+}
+