about summary refs log tree commit diff
path: root/pkgs/servers/matrix-synapse/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/servers/matrix-synapse/plugins')
-rw-r--r--pkgs/servers/matrix-synapse/plugins/default.nix6
-rw-r--r--pkgs/servers/matrix-synapse/plugins/ldap3.nix17
-rw-r--r--pkgs/servers/matrix-synapse/plugins/pam.nix15
3 files changed, 38 insertions, 0 deletions
diff --git a/pkgs/servers/matrix-synapse/plugins/default.nix b/pkgs/servers/matrix-synapse/plugins/default.nix
new file mode 100644
index 000000000000..f3dbaa1573f0
--- /dev/null
+++ b/pkgs/servers/matrix-synapse/plugins/default.nix
@@ -0,0 +1,6 @@
+{ callPackage }:
+
+{
+  matrix-synapse-ldap3 = callPackage ./ldap3.nix { };
+  matrix-synapse-pam = callPackage ./pam.nix { };
+}
diff --git a/pkgs/servers/matrix-synapse/plugins/ldap3.nix b/pkgs/servers/matrix-synapse/plugins/ldap3.nix
new file mode 100644
index 000000000000..9f1aec20033b
--- /dev/null
+++ b/pkgs/servers/matrix-synapse/plugins/ldap3.nix
@@ -0,0 +1,17 @@
+{ isPy3k, buildPythonPackage, fetchPypi, service-identity, ldap3, twisted, ldaptor, mock }:
+
+buildPythonPackage rec {
+  pname = "matrix-synapse-ldap3";
+  version = "0.1.4";
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "01bms89sl16nyh9f141idsz4mnhxvjrc3gj721wxh1fhikps0djx";
+  };
+
+  propagatedBuildInputs = [ service-identity ldap3 twisted ];
+
+  # ldaptor is not ready for py3 yet
+  doCheck = !isPy3k;
+  checkInputs = [ ldaptor mock ];
+}
diff --git a/pkgs/servers/matrix-synapse/plugins/pam.nix b/pkgs/servers/matrix-synapse/plugins/pam.nix
new file mode 100644
index 000000000000..47ee28a7794c
--- /dev/null
+++ b/pkgs/servers/matrix-synapse/plugins/pam.nix
@@ -0,0 +1,15 @@
+{ buildPythonPackage, fetchFromGitHub, twisted, python-pam }:
+
+buildPythonPackage rec {
+  pname = "matrix-synapse-pam";
+  version = "0.1.2";
+
+  src = fetchFromGitHub {
+    owner = "14mRh4X0r";
+    repo = "matrix-synapse-pam";
+    rev = "v${version}";
+    sha256 = "10byma9hxz3g4sirw5sa4pvljn83h9vs7zc15chhpl2n14bdx45l";
+  };
+
+  propagatedBuildInputs = [ twisted python-pam ];
+}