2019-09-21 10:26:00 +01:00
|
|
|
{ lib, buildGoPackage, fetchFromGitHub }:
|
2017-06-03 22:34:31 +01:00
|
|
|
|
2019-09-21 10:26:00 +01:00
|
|
|
buildGoPackage rec {
|
2019-04-25 23:02:43 +01:00
|
|
|
pname = "dex";
|
2020-06-15 20:44:30 +01:00
|
|
|
version = "2.23.0";
|
2017-06-03 22:34:31 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2019-04-25 23:02:43 +01:00
|
|
|
owner = "dexidp";
|
|
|
|
repo = pname;
|
2019-07-10 19:18:42 +01:00
|
|
|
rev = "v${version}";
|
2020-06-15 20:44:30 +01:00
|
|
|
sha256 = "1fr5r7d0xwj0b69jhszyyif4yc4kiy7zpfcpf83zdy12mh8f96c8";
|
2017-06-03 22:34:31 +01:00
|
|
|
};
|
|
|
|
|
2019-09-21 10:26:00 +01:00
|
|
|
goPackagePath = "github.com/dexidp/dex";
|
2019-07-10 19:18:42 +01:00
|
|
|
|
2017-06-03 22:34:31 +01:00
|
|
|
subPackages = [
|
|
|
|
"cmd/dex"
|
|
|
|
];
|
|
|
|
|
|
|
|
buildFlagsArray = [
|
2019-07-10 19:18:42 +01:00
|
|
|
"-ldflags=-w -X github.com/dexidp/dex/version.Version=${src.rev}"
|
2017-06-03 22:34:31 +01:00
|
|
|
];
|
|
|
|
|
2019-04-25 23:36:27 +01:00
|
|
|
postInstall = ''
|
2020-04-28 02:50:57 +01:00
|
|
|
mkdir -p $out/share
|
|
|
|
cp -r $src/web $out/share/web
|
2019-04-25 23:36:27 +01:00
|
|
|
'';
|
|
|
|
|
2019-07-10 19:18:42 +01:00
|
|
|
meta = with lib; {
|
2017-06-03 22:34:31 +01:00
|
|
|
description = "OpenID Connect and OAuth2 identity provider with pluggable connectors";
|
2019-07-10 19:18:42 +01:00
|
|
|
homepage = "https://github.com/dexidp/dex";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ benley ];
|
|
|
|
platforms = platforms.unix;
|
2017-06-03 22:34:31 +01:00
|
|
|
};
|
|
|
|
}
|