From 7f6f990d53d919d51c88e87af970b168fa61acab Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 8 Jul 2020 11:45:57 +0200 Subject: [PATCH 1/4] certbot: 1.3.0 -> 1.6.0 This includes https://github.com/certbot/certbot/pull/8081, so we can stop shipping our custom patch to workaroung things, and start packaging more certbot plugins. Other release notes: - https://github.com/certbot/certbot/releases/tag/v1.4.0 - https://github.com/certbot/certbot/releases/tag/v1.5.0 - https://github.com/certbot/certbot/releases/tag/v1.6.0 --- ...ils.StrictVersion-that-cannot-handle.patch | 58 ------------------- pkgs/tools/admin/certbot/default.nix | 8 +-- 2 files changed, 2 insertions(+), 64 deletions(-) delete mode 100644 pkgs/tools/admin/certbot/0001-Don-t-use-distutils.StrictVersion-that-cannot-handle.patch diff --git a/pkgs/tools/admin/certbot/0001-Don-t-use-distutils.StrictVersion-that-cannot-handle.patch b/pkgs/tools/admin/certbot/0001-Don-t-use-distutils.StrictVersion-that-cannot-handle.patch deleted file mode 100644 index 789efd185ca..00000000000 --- a/pkgs/tools/admin/certbot/0001-Don-t-use-distutils.StrictVersion-that-cannot-handle.patch +++ /dev/null @@ -1,58 +0,0 @@ -From 0de195de31dc311976af52a7c2b547bc23af2691 Mon Sep 17 00:00:00 2001 -From: Frederik Rietdijk -Date: Sat, 14 Dec 2019 19:27:14 +0100 -Subject: [PATCH] Don't use distutils.StrictVersion that cannot handle certain - versions - -``` - File "setup.py", line 63, in - if StrictVersion(setuptools_version) >= StrictVersion('36.2'): -File -"/nix/store/zdh16dcvjw99ybam59zd2ijb6bx138j0-python3-3.7.5/lib/python3.7/distutils/version.py", -line 40, in __init__ - self.parse(vstring) -File -"/nix/store/zdh16dcvjw99ybam59zd2ijb6bx138j0-python3-3.7.5/lib/python3.7/distutils/version.py", -line 137, in parse - raise ValueError("invalid version number '%s'" % vstring) -ValueError: invalid version number '41.4.0.post20191022' -``` ---- - certbot/setup.py | 15 +-------------- - 1 file changed, 1 insertion(+), 14 deletions(-) - -diff --git a/certbot/setup.py b/certbot/setup.py -index d19327e5e..ac1524793 100644 ---- a/certbot/setup.py -+++ b/certbot/setup.py -@@ -1,5 +1,4 @@ - import codecs --from distutils.version import StrictVersion - import os - import re - import sys -@@ -58,20 +57,8 @@ install_requires = [ - - # Add pywin32 on Windows platforms to handle low-level system calls. - # This dependency needs to be added using environment markers to avoid its installation on Linux. --# However environment markers are supported only with setuptools >= 36.2. --# So this dependency is not added for old Linux distributions with old setuptools, --# in order to allow these systems to build certbot from sources. - pywin32_req = 'pywin32>=227' # do not forget to edit pywin32 dependency accordingly in windows-installer/construct.py --if StrictVersion(setuptools_version) >= StrictVersion('36.2'): -- install_requires.append(pywin32_req + " ; sys_platform == 'win32'") --elif 'bdist_wheel' in sys.argv[1:]: -- raise RuntimeError('Error, you are trying to build certbot wheels using an old version ' -- 'of setuptools. Version 36.2+ of setuptools is required.') --elif os.name == 'nt': -- # This branch exists to improve this package's behavior on Windows. Without -- # it, if the sdist is installed on Windows with an old version of -- # setuptools, pywin32 will not be specified as a dependency. -- install_requires.append(pywin32_req) -+install_requires.append(pywin32_req + " ; sys_platform == 'win32'") - - dev_extras = [ - 'coverage', --- -2.24.1 - diff --git a/pkgs/tools/admin/certbot/default.nix b/pkgs/tools/admin/certbot/default.nix index cabf335fb69..67d698a64fa 100644 --- a/pkgs/tools/admin/certbot/default.nix +++ b/pkgs/tools/admin/certbot/default.nix @@ -8,19 +8,15 @@ buildPythonApplication rec { pname = "certbot"; - version = "1.3.0"; + version = "1.6.0"; src = fetchFromGitHub { owner = pname; repo = pname; rev = "v${version}"; - sha256 = "1nzp1l63f64qqp89y1vyd4lgfhykfp5dkr6iwfiyf273y7sjwpsa"; + sha256 = "1y0m5qm853i6pcpb2mrf8kjkr9wr80mdrx1qmck38ayvr2v2p5lc"; }; - patches = [ - ./0001-Don-t-use-distutils.StrictVersion-that-cannot-handle.patch - ]; - propagatedBuildInputs = [ ConfigArgParse acme From 9b4364d703fff6d78d1be42bcacfbd54d2f2ece8 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 8 Jul 2020 12:55:03 +0200 Subject: [PATCH 2/4] python3.pkgs.certbot-dns-cloudflare: init at 1.6.0 --- .../certbot-dns-cloudflare/default.nix | 35 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 37 insertions(+) create mode 100644 pkgs/development/python-modules/certbot-dns-cloudflare/default.nix diff --git a/pkgs/development/python-modules/certbot-dns-cloudflare/default.nix b/pkgs/development/python-modules/certbot-dns-cloudflare/default.nix new file mode 100644 index 00000000000..6c14f6c472f --- /dev/null +++ b/pkgs/development/python-modules/certbot-dns-cloudflare/default.nix @@ -0,0 +1,35 @@ +{ buildPythonPackage +, acme +, certbot +, cloudflare +, isPy3k +, pytest +, pytestCheckHook +}: + +buildPythonPackage rec { + inherit (certbot) src version; + + pname = "certbot-dns-cloudflare"; + + propagatedBuildInputs = [ + acme + certbot + cloudflare + ]; + + checkInputs = [ + pytest + pytestCheckHook + ]; + + disabled = !isPy3k; + + pytestFlagsArray = [ "-o cache_dir=$(mktemp -d)" ]; + + sourceRoot = "source/${pname}"; + + meta = certbot.meta // { + description = "Cloudflare DNS Authenticator plugin for Certbot"; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 35deab0785a..1c5e7081796 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -579,6 +579,8 @@ in { cdecimal = callPackage ../development/python-modules/cdecimal { }; + certbot-dns-cloudflare = callPackage ../development/python-modules/certbot-dns-cloudflare { }; + cfn-flip = callPackage ../development/python-modules/cfn-flip { }; chalice = callPackage ../development/python-modules/chalice { }; From b9d97f313bd0db39a897f27b3e829b0c3d711220 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 8 Jul 2020 13:02:02 +0200 Subject: [PATCH 3/4] python3.pkgs.certbot-dns-route53: init at 1.6.0 --- .../certbot-dns-route53/default.nix | 35 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 37 insertions(+) create mode 100644 pkgs/development/python-modules/certbot-dns-route53/default.nix diff --git a/pkgs/development/python-modules/certbot-dns-route53/default.nix b/pkgs/development/python-modules/certbot-dns-route53/default.nix new file mode 100644 index 00000000000..6fba51ce92a --- /dev/null +++ b/pkgs/development/python-modules/certbot-dns-route53/default.nix @@ -0,0 +1,35 @@ +{ buildPythonPackage +, acme +, boto3 +, certbot +, isPy3k +, pytest +, pytestCheckHook +}: + +buildPythonPackage rec { + inherit (certbot) src version; + + pname = "certbot-dns-route53"; + + propagatedBuildInputs = [ + acme + boto3 + certbot + ]; + + checkInputs = [ + pytest + pytestCheckHook + ]; + + disabled = !isPy3k; + + pytestFlagsArray = [ "-o cache_dir=$(mktemp -d)" ]; + + sourceRoot = "source/${pname}"; + + meta = certbot.meta // { + description = "Route53 DNS Authenticator plugin for Certbot"; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 1c5e7081796..99e8975e385 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -581,6 +581,8 @@ in { certbot-dns-cloudflare = callPackage ../development/python-modules/certbot-dns-cloudflare { }; + certbot-dns-route53 = callPackage ../development/python-modules/certbot-dns-route53 { }; + cfn-flip = callPackage ../development/python-modules/cfn-flip { }; chalice = callPackage ../development/python-modules/chalice { }; From ee9123ddb9894b3ff0796f7895bc28603e1b27f1 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 8 Jul 2020 13:36:19 +0200 Subject: [PATCH 4/4] python3.pkgs.certbot-dns-rfc2136: init at 1.6.0 --- .../certbot-dns-rfc2136/default.nix | 35 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 37 insertions(+) create mode 100644 pkgs/development/python-modules/certbot-dns-rfc2136/default.nix diff --git a/pkgs/development/python-modules/certbot-dns-rfc2136/default.nix b/pkgs/development/python-modules/certbot-dns-rfc2136/default.nix new file mode 100644 index 00000000000..19e53aa20cc --- /dev/null +++ b/pkgs/development/python-modules/certbot-dns-rfc2136/default.nix @@ -0,0 +1,35 @@ +{ buildPythonPackage +, acme +, certbot +, dnspython +, isPy3k +, pytest +, pytestCheckHook +}: + +buildPythonPackage rec { + inherit (certbot) src version; + + pname = "certbot-dns-rfc2136"; + + propagatedBuildInputs = [ + acme + certbot + dnspython + ]; + + checkInputs = [ + pytest + pytestCheckHook + ]; + + disabled = !isPy3k; + + pytestFlagsArray = [ "-o cache_dir=$(mktemp -d)" ]; + + sourceRoot = "source/${pname}"; + + meta = certbot.meta // { + description = "RFC 2136 DNS Authenticator plugin for Certbot"; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 99e8975e385..4340f6a30ee 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -581,6 +581,8 @@ in { certbot-dns-cloudflare = callPackage ../development/python-modules/certbot-dns-cloudflare { }; + certbot-dns-rfc2136 = callPackage ../development/python-modules/certbot-dns-rfc2136 { }; + certbot-dns-route53 = callPackage ../development/python-modules/certbot-dns-route53 { }; cfn-flip = callPackage ../development/python-modules/cfn-flip { };