2018-03-20 22:25:50 +01:00
|
|
|
{ stdenv, pythonPackages, fetchFromGitHub, dialog }:
|
2015-10-31 22:01:20 +01:00
|
|
|
|
2016-11-08 15:16:06 +01:00
|
|
|
# Latest version of certbot supports python3 and python3 version of pythondialog
|
|
|
|
|
2018-03-20 22:25:50 +01:00
|
|
|
pythonPackages.buildPythonApplication rec {
|
2016-05-16 22:39:34 +02:00
|
|
|
name = "certbot-${version}";
|
2018-05-07 14:13:43 +02:00
|
|
|
version = "0.24.0";
|
2015-12-05 08:34:50 +01:00
|
|
|
|
2016-01-04 01:54:22 +01:00
|
|
|
src = fetchFromGitHub {
|
2016-05-09 17:28:52 +02:00
|
|
|
owner = "certbot";
|
|
|
|
repo = "certbot";
|
2016-01-04 01:54:22 +01:00
|
|
|
rev = "v${version}";
|
2018-05-07 14:13:43 +02:00
|
|
|
sha256 = "0gsq4si0bqwzd7ywf87y7bbprqg1m72qdj11h64qmwb5zl4vh444";
|
2015-10-31 22:01:20 +01:00
|
|
|
};
|
|
|
|
|
2018-03-20 22:25:50 +01:00
|
|
|
propagatedBuildInputs = with pythonPackages; [
|
2016-01-04 01:54:22 +01:00
|
|
|
ConfigArgParse
|
|
|
|
acme
|
|
|
|
configobj
|
|
|
|
cryptography
|
|
|
|
parsedatetime
|
|
|
|
psutil
|
|
|
|
pyRFC3339
|
|
|
|
pyopenssl
|
|
|
|
python2-pythondialog
|
|
|
|
pytz
|
|
|
|
six
|
|
|
|
zope_component
|
|
|
|
zope_interface
|
2015-10-31 22:01:20 +01:00
|
|
|
];
|
2018-03-20 22:25:50 +01:00
|
|
|
buildInputs = [ dialog ] ++ (with pythonPackages; [ nose mock gnureadline ]);
|
2015-10-31 22:01:20 +01:00
|
|
|
|
|
|
|
patchPhase = ''
|
2017-01-29 11:11:01 +01:00
|
|
|
substituteInPlace certbot/notify.py --replace "/usr/sbin/sendmail" "/run/wrappers/bin/sendmail"
|
2016-12-13 12:00:27 +01:00
|
|
|
substituteInPlace certbot/util.py --replace "sw_vers" "/usr/bin/sw_vers"
|
2015-10-31 22:01:20 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
for i in $out/bin/*; do
|
|
|
|
wrapProgram "$i" --prefix PYTHONPATH : "$PYTHONPATH" \
|
|
|
|
--prefix PATH : "${dialog}/bin:$PATH"
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2018-06-03 22:41:36 +02:00
|
|
|
doCheck = !stdenv.isDarwin; # On Hydra Darwin tests fail with "Too many open files".
|
|
|
|
|
2015-10-31 22:01:20 +01:00
|
|
|
meta = with stdenv.lib; {
|
2016-05-09 17:28:52 +02:00
|
|
|
homepage = src.meta.homepage;
|
2015-10-31 22:01:20 +01:00
|
|
|
description = "ACME client that can obtain certs and extensibly update server configurations";
|
|
|
|
platforms = platforms.unix;
|
2016-05-17 13:57:28 +02:00
|
|
|
maintainers = [ maintainers.domenkozar ];
|
2015-10-31 22:05:12 +01:00
|
|
|
license = licenses.asl20;
|
2015-10-31 22:01:20 +01:00
|
|
|
};
|
|
|
|
}
|