Merge pull request #131401 from SuperSandro2000/fail2ban

fail2ban: cleanup

authored by Sandro and committed by GitHub 6df60038 b4d7ca16

+16 -15
+16 -15
pkgs/tools/security/fail2ban/default.nix
··· 1 1 { lib, stdenv, fetchFromGitHub, python3 }: 2 2 3 - let version = "0.11.2"; in 4 3 5 - python3.pkgs.buildPythonApplication { 4 + python3.pkgs.buildPythonApplication rec { 6 5 pname = "fail2ban"; 7 - inherit version; 6 + version = "0.11.2"; 8 7 9 8 src = fetchFromGitHub { 10 - owner = "fail2ban"; 11 - repo = "fail2ban"; 12 - rev = version; 9 + owner = "fail2ban"; 10 + repo = "fail2ban"; 11 + rev = version; 13 12 sha256 = "q4U9iWCa1zg8sA+6pPNejt6v/41WGIKN5wITJCrCqQE="; 14 13 }; 15 14 ··· 42 41 ${stdenv.shell} ./fail2ban-2to3 43 42 ''; 44 43 45 - postInstall = let 46 - sitePackages = "$out/${python3.sitePackages}"; 47 - in '' 48 - # see https://github.com/NixOS/nixpkgs/issues/4968 49 - rm -rf ${sitePackages}/etc ${sitePackages}/usr ${sitePackages}/var; 50 - ''; 44 + postInstall = 45 + let 46 + sitePackages = "$out/${python3.sitePackages}"; 47 + in 48 + '' 49 + # see https://github.com/NixOS/nixpkgs/issues/4968 50 + rm -r ${sitePackages}/etc ${sitePackages}/usr 51 + ''; 51 52 52 53 meta = with lib; { 53 - homepage = "https://www.fail2ban.org/"; 54 + homepage = "https://www.fail2ban.org/"; 54 55 description = "A program that scans log files for repeated failing login attempts and bans IP addresses"; 55 - license = licenses.gpl2Plus; 56 + license = licenses.gpl2Plus; 56 57 maintainers = with maintainers; [ eelco lovek323 fpletz ]; 57 - platforms = platforms.linux ++ platforms.darwin; 58 + platforms = platforms.unix; 58 59 }; 59 60 }