2023-08-22 20:05:09 +00:00
|
|
|
{ lib, stdenv, buildPythonPackage, fetchFromGitHub, matrix-synapse-unwrapped }:
|
2021-05-28 09:39:13 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "matrix-synapse-mjolnir-antispam";
|
2023-02-22 10:55:15 +00:00
|
|
|
version = "1.6.4";
|
2021-05-28 09:39:13 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "matrix-org";
|
|
|
|
repo = "mjolnir";
|
2022-05-18 14:49:53 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-02-22 10:55:15 +00:00
|
|
|
sha256 = "sha256-/vnojWLpu/fktqPUhAdL1QTESxDwFrBVYAkyF79Fj9w=";
|
2021-05-28 09:39:13 +00:00
|
|
|
};
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
sourceRoot = "${src.name}/synapse_antispam";
|
2021-05-28 09:39:13 +00:00
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
buildInputs = [ matrix-synapse-unwrapped ];
|
2021-05-28 09:39:13 +00:00
|
|
|
|
|
|
|
doCheck = false; # no tests
|
|
|
|
pythonImportsCheck = [ "mjolnir" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "AntiSpam / Banlist plugin to be used with mjolnir";
|
|
|
|
longDescription = ''
|
|
|
|
Primarily meant to block invites from undesired homeservers/users,
|
|
|
|
Mjolnir's Synapse module is a way to interpret ban lists and apply
|
|
|
|
them to your entire homeserver.
|
|
|
|
'';
|
2023-03-04 12:14:45 +00:00
|
|
|
homepage = "https://github.com/matrix-org/mjolnir/blob/main/docs/synapse_module.md";
|
2021-05-28 09:39:13 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ jojosch ];
|
2023-03-04 12:14:45 +00:00
|
|
|
broken = stdenv.isDarwin;
|
2021-05-28 09:39:13 +00:00
|
|
|
};
|
|
|
|
}
|