From 95d96e1d7b242a26299089d58b7f4a92b5377232 Mon Sep 17 00:00:00 2001 From: Sumner Evans Date: Wed, 19 Mar 2025 10:10:21 -0600 Subject: [PATCH] synapse-http-antispam: init at 0.3.0 https://github.com/maunium/synapse-http-antispam/releases/tag/v0.3.0 Co-authored-by: Ethan Carter Edwards Signed-off-by: Sumner Evans --- .../plugins/default.nix | 1 + .../plugins/synapse-http-antispam.nix | 39 +++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/synapse-http-antispam.nix diff --git a/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/default.nix b/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/default.nix index 1f35ae050241..6736dbd6f313 100644 --- a/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/default.nix +++ b/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/default.nix @@ -7,4 +7,5 @@ matrix-synapse-pam = callPackage ./pam.nix { }; matrix-synapse-s3-storage-provider = callPackage ./s3-storage-provider.nix { }; matrix-synapse-shared-secret-auth = callPackage ./shared-secret-auth.nix { }; + synapse-http-antispam = callPackage ./synapse-http-antispam.nix { }; } diff --git a/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/synapse-http-antispam.nix b/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/synapse-http-antispam.nix new file mode 100644 index 000000000000..f09938a98ec7 --- /dev/null +++ b/pkgs/by-name/ma/matrix-synapse-unwrapped/plugins/synapse-http-antispam.nix @@ -0,0 +1,39 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + hatchling, + matrix-synapse-unwrapped, + nix-update-script, + twisted, +}: + +buildPythonPackage rec { + pname = "synapse-http-antispam"; + version = "0.3.0"; + pyproject = true; + + src = fetchFromGitHub { + owner = "maunium"; + repo = "synapse-http-antispam"; + tag = "v${version}"; + hash = "sha256-wWm23+3o+/nx3xGkyShJm28mDPTbOhPbKgW3WfuB0Ng="; + }; + + build-system = [ hatchling ]; + + pythonImportsCheck = [ "synapse_http_antispam" ]; + + buildInputs = [ matrix-synapse-unwrapped ]; + dependencies = [ twisted ]; + + passthru.updateScript = nix-update-script { }; + + meta = { + description = "Synapse module that forwards spam checking to an HTTP server"; + homepage = "https://github.com/maunium/synapse-http-antispam"; + changelog = "https://github.com/maunium/synapse-http-antispam/releases/tag/v${version}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ sumnerevans ]; + }; +}