2017-07-21 15:45:03 +00:00
|
|
|
{ stdenv, buildGoPackage, fetchFromGitHub }:
|
|
|
|
|
|
|
|
buildGoPackage rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "dgraph";
|
2019-09-01 02:15:52 +00:00
|
|
|
version = "1.0.17";
|
2017-07-21 15:45:03 +00:00
|
|
|
|
|
|
|
goPackagePath = "github.com/dgraph-io/dgraph";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "dgraph-io";
|
|
|
|
repo = "dgraph";
|
|
|
|
rev = "v${version}";
|
2019-09-01 02:15:52 +00:00
|
|
|
sha256 = "05z1xwbd76q49zyqahh9krvq78dgkzr22qc6srr4djds0l7y6x5i";
|
2017-07-21 15:45:03 +00:00
|
|
|
};
|
|
|
|
|
2019-09-01 02:15:52 +00:00
|
|
|
# see licensing
|
|
|
|
buildFlags = [ "-tags oss" ];
|
2017-07-21 15:45:03 +00:00
|
|
|
|
|
|
|
goDeps = ./deps.nix;
|
2019-09-01 02:15:52 +00:00
|
|
|
subPackages = [ "dgraph"];
|
2017-07-21 15:45:03 +00:00
|
|
|
|
|
|
|
preBuild = ''
|
|
|
|
export buildFlagsArray="-ldflags=\
|
2019-09-01 02:15:52 +00:00
|
|
|
-X github.com/dgraph-io/dgraph/x.dgraphVersion=${version}"
|
2017-07-21 15:45:03 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "https://dgraph.io/";
|
|
|
|
description = "Fast, Distributed Graph DB";
|
|
|
|
maintainers = with stdenv.lib.maintainers; [ sigma ];
|
2019-09-01 02:15:52 +00:00
|
|
|
# Apache 2.0 because we use only build tag "oss"
|
|
|
|
license = stdenv.lib.licenses.asl20;
|
2017-07-21 15:45:03 +00:00
|
|
|
platforms = stdenv.lib.platforms.unix;
|
|
|
|
};
|
|
|
|
}
|