at 24.05-pre 45 lines 1.3 kB view raw
1{ lib, buildGoPackage, fetchFromGitHub, fetchpatch }: 2 3let 4 generic = { patches ? [] }: 5 buildGoPackage rec { 6 version = "1.6.4"; 7 pname = "certmgr"; 8 9 goPackagePath = "github.com/cloudflare/certmgr/"; 10 11 src = fetchFromGitHub { 12 owner = "cloudflare"; 13 repo = "certmgr"; 14 rev = "v${version}"; 15 sha256 = "0glvyp61ya21pdm2bsvq3vfhmmxc2998vxc6hiyc79ijsv9n6jqi"; 16 }; 17 18 inherit patches; 19 20 meta = with lib; { 21 homepage = "https://cfssl.org/"; 22 description = "Cloudflare's certificate manager"; 23 platforms = platforms.linux; 24 license = licenses.bsd2; 25 maintainers = with maintainers; [ johanot srhb ]; 26 }; 27 }; 28in 29{ 30 certmgr = generic {}; 31 32 certmgr-selfsigned = generic { 33 # The following patch makes it possible to use a self-signed x509 cert 34 # for the cfssl apiserver. 35 # TODO: remove patch when PR is merged. 36 patches = [ 37 (fetchpatch { 38 # https://github.com/cloudflare/certmgr/pull/51 39 name = "cloudflare-certmgr-pull-51.patch"; 40 url = "https://github.com/cloudflare/certmgr/compare/232e0adf8379db28ab74c46e0dd3eddb3cd8f2ea...55c595a4a2dc871726b3c8337469daf5597718a3.patch"; 41 sha256 = "0jhsw159d2mgybvbbn6pmvj4yqr5cwcal5fjwkcn9m4f4zlb6qrs"; 42 }) 43 ]; 44 }; 45}