about summary refs log tree commit diff
path: root/pkgs/top-level/perl-packages.nix
diff options
context:
space:
mode:
authorStig Palmquist <stig@stig.io>2022-01-30 19:18:50 +0100
committerStig Palmquist <stig@stig.io>2022-01-30 19:20:38 +0100
commit52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa (patch)
tree1a008030acfaf1a57aeefb0848d9e0c6eb86a5f8 /pkgs/top-level/perl-packages.nix
parent9cbd42c6ded3e48d221c766d1a23a29836c516a8 (diff)
downloadnixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar.gz
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar.bz2
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar.lz
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar.xz
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.tar.zst
nixlib-52cac2a6e484f0ea9f7cc2520df18e69f3d4b7aa.zip
perlPackages.Appcpanminus: use TLS endpoints by default
Diffstat (limited to 'pkgs/top-level/perl-packages.nix')
-rw-r--r--pkgs/top-level/perl-packages.nix8
1 files changed, 8 insertions, 0 deletions
diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix
index 76d381a72c2b..0550d0a2deb0 100644
--- a/pkgs/top-level/perl-packages.nix
+++ b/pkgs/top-level/perl-packages.nix
@@ -734,6 +734,14 @@ let
       url = "mirror://cpan/authors/id/M/MI/MIYAGAWA/App-cpanminus-1.7045.tar.gz";
       sha256 = "1779w07zxlgfk35s24ksr7k9azd5yl8sbb48y1aaph7y4gf4lkmc";
     };
+    # Use TLS endpoints for downloads and metadata by default
+    preConfigure = ''
+      substituteInPlace bin/cpanm \
+        --replace http://www.cpan.org https://www.cpan.org \
+        --replace http://backpan.perl.org https://backpan.perl.org \
+        --replace http://fastapi.metacpan.org https://fastapi.metacpan.org \
+        --replace http://cpanmetadb.plackperl.org https://cpanmetadb.plackperl.org
+    '';
     propagatedBuildInputs = [ IOSocketSSL ];
     meta = {
       homepage = "https://github.com/miyagawa/cpanminus";