2021-01-25 08:26:54 +00:00
|
|
|
{ lib, buildGoPackage, fetchFromGitHub, fetchpatch }:
|
2018-08-03 15:52:15 +01:00
|
|
|
|
2019-01-24 11:10:33 +00:00
|
|
|
let
|
|
|
|
generic = { patches ? [] }:
|
|
|
|
buildGoPackage rec {
|
2019-02-25 16:26:00 +00:00
|
|
|
version = "1.6.4";
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "certmgr";
|
2018-08-03 15:52:15 +01:00
|
|
|
|
2019-01-24 11:10:33 +00:00
|
|
|
goPackagePath = "github.com/cloudflare/certmgr/";
|
2018-08-03 15:52:15 +01:00
|
|
|
|
2019-01-24 11:10:33 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "cloudflare";
|
|
|
|
repo = "certmgr";
|
|
|
|
rev = "v${version}";
|
2019-02-25 16:26:00 +00:00
|
|
|
sha256 = "0glvyp61ya21pdm2bsvq3vfhmmxc2998vxc6hiyc79ijsv9n6jqi";
|
2019-01-24 11:10:33 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
inherit patches;
|
2018-08-03 15:52:15 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://cfssl.org/";
|
2019-01-24 11:10:33 +00:00
|
|
|
description = "Cloudflare's certificate manager";
|
|
|
|
platforms = platforms.linux;
|
|
|
|
license = licenses.bsd2;
|
|
|
|
maintainers = with maintainers; [ johanot srhb ];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
in
|
|
|
|
{
|
|
|
|
certmgr = generic {};
|
2018-08-24 10:54:21 +01:00
|
|
|
|
2019-01-24 11:10:33 +00:00
|
|
|
certmgr-selfsigned = generic {
|
|
|
|
# The following patch makes it possible to use a self-signed x509 cert
|
|
|
|
# for the cfssl apiserver.
|
|
|
|
# TODO: remove patch when PR is merged.
|
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/cloudflare/certmgr/pull/51.patch";
|
|
|
|
sha256 = "0jhsw159d2mgybvbbn6pmvj4yqr5cwcal5fjwkcn9m4f4zlb6qrs";
|
|
|
|
})
|
|
|
|
];
|
2018-08-03 15:52:15 +01:00
|
|
|
};
|
|
|
|
}
|