diff options
| author | Gregor Kleen <gkleen@yggdrasil.li> | 2022-11-07 22:43:26 +0100 |
|---|---|---|
| committer | Gregor Kleen <gkleen@yggdrasil.li> | 2022-11-07 22:43:26 +0100 |
| commit | 5b3c59bf26ff8b9c38f3ca78451b42ad0014a585 (patch) | |
| tree | 515f43dc3a8543f6ca2e7afdd565885e8903e7e6 /overlays | |
| parent | c80473dbef4ca003642322e7243affe52eef4b06 (diff) | |
| download | nixos-5b3c59bf26ff8b9c38f3ca78451b42ad0014a585.tar nixos-5b3c59bf26ff8b9c38f3ca78451b42ad0014a585.tar.gz nixos-5b3c59bf26ff8b9c38f3ca78451b42ad0014a585.tar.bz2 nixos-5b3c59bf26ff8b9c38f3ca78451b42ad0014a585.tar.xz nixos-5b3c59bf26ff8b9c38f3ca78451b42ad0014a585.zip | |
...
Diffstat (limited to 'overlays')
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/default.nix | 111 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/plugins/default.nix | 8 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/plugins/ldap3.nix | 17 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/plugins/mjolnir-antispam.nix | 32 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/plugins/pam.nix | 15 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/plugins/shared-secret-auth.nix | 26 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/tools/default.nix | 6 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/tools/rust-synapse-compress-state.nix | 30 | ||||
| -rw-r--r-- | overlays/matrix-synapse/1.70.1/tools/synadm.nix | 47 | ||||
| -rw-r--r-- | overlays/matrix-synapse/default.nix | 3 | ||||
| -rw-r--r-- | overlays/postfix-mta-sts-resolver.nix | 24 |
11 files changed, 13 insertions, 306 deletions
diff --git a/overlays/matrix-synapse/1.70.1/default.nix b/overlays/matrix-synapse/1.70.1/default.nix deleted file mode 100644 index 0c026914..00000000 --- a/overlays/matrix-synapse/1.70.1/default.nix +++ /dev/null | |||
| @@ -1,111 +0,0 @@ | |||
| 1 | { lib, stdenv, fetchFromGitHub, python3, openssl, rustPlatform | ||
| 2 | , enableSystemd ? stdenv.isLinux, nixosTests | ||
| 3 | , enableRedis ? true | ||
| 4 | , callPackage | ||
| 5 | }: | ||
| 6 | |||
| 7 | let | ||
| 8 | plugins = python3.pkgs.callPackage ./plugins { }; | ||
| 9 | tools = callPackage ./tools { }; | ||
| 10 | in | ||
| 11 | with python3.pkgs; | ||
| 12 | buildPythonApplication rec { | ||
| 13 | pname = "matrix-synapse"; | ||
| 14 | version = "1.70.1"; | ||
| 15 | format = "pyproject"; | ||
| 16 | |||
| 17 | src = fetchFromGitHub { | ||
| 18 | owner = "matrix-org"; | ||
| 19 | repo = "synapse"; | ||
| 20 | rev = "v${version}"; | ||
| 21 | hash = "sha256-/clEY3sabaDEOAAowQ896vYOvzf5Teevoa7ZkzWw+fY="; | ||
| 22 | }; | ||
| 23 | |||
| 24 | cargoDeps = rustPlatform.fetchCargoTarball { | ||
| 25 | inherit src; | ||
| 26 | name = "${pname}-${version}"; | ||
| 27 | hash = "sha256-9wxWxrn+uPcz60710DROhDqNC6FvTtnqzWiWRk8kl6A="; | ||
| 28 | }; | ||
| 29 | |||
| 30 | postPatch = '' | ||
| 31 | # Remove setuptools_rust from runtime dependencies | ||
| 32 | # https://github.com/matrix-org/synapse/blob/v1.69.0/pyproject.toml#L177-L185 | ||
| 33 | sed -i '/^setuptools_rust =/d' pyproject.toml | ||
| 34 | ''; | ||
| 35 | |||
| 36 | nativeBuildInputs = [ | ||
| 37 | poetry-core | ||
| 38 | rustPlatform.cargoSetupHook | ||
| 39 | setuptools-rust | ||
| 40 | ] ++ (with rustPlatform.rust; [ | ||
| 41 | cargo | ||
| 42 | rustc | ||
| 43 | ]); | ||
| 44 | |||
| 45 | buildInputs = [ openssl ]; | ||
| 46 | |||
| 47 | propagatedBuildInputs = [ | ||
| 48 | authlib | ||
| 49 | bcrypt | ||
| 50 | bleach | ||
| 51 | canonicaljson | ||
| 52 | daemonize | ||
| 53 | frozendict | ||
| 54 | ijson | ||
| 55 | jinja2 | ||
| 56 | jsonschema | ||
| 57 | lxml | ||
| 58 | matrix-common | ||
| 59 | msgpack | ||
| 60 | netaddr | ||
| 61 | phonenumbers | ||
| 62 | pillow | ||
| 63 | prometheus-client | ||
| 64 | psutil | ||
| 65 | psycopg2 | ||
| 66 | pyasn1 | ||
| 67 | pydantic | ||
| 68 | pyjwt | ||
| 69 | pymacaroons | ||
| 70 | pynacl | ||
| 71 | pyopenssl | ||
| 72 | pysaml2 | ||
| 73 | pyyaml | ||
| 74 | requests | ||
| 75 | setuptools | ||
| 76 | signedjson | ||
| 77 | sortedcontainers | ||
| 78 | treq | ||
| 79 | twisted | ||
| 80 | typing-extensions | ||
| 81 | unpaddedbase64 | ||
| 82 | ] ++ lib.optional enableSystemd systemd | ||
| 83 | ++ lib.optionals enableRedis [ hiredis txredisapi ]; | ||
| 84 | |||
| 85 | checkInputs = [ mock parameterized openssl ]; | ||
| 86 | |||
| 87 | doCheck = !stdenv.isDarwin; | ||
| 88 | |||
| 89 | checkPhase = '' | ||
| 90 | runHook preCheck | ||
| 91 | |||
| 92 | # remove src module, so tests use the installed module instead | ||
| 93 | rm -rf ./synapse | ||
| 94 | |||
| 95 | PYTHONPATH=".:$PYTHONPATH" ${python3.interpreter} -m twisted.trial -j $NIX_BUILD_CORES tests | ||
| 96 | |||
| 97 | runHook postCheck | ||
| 98 | ''; | ||
| 99 | |||
| 100 | passthru.tests = { inherit (nixosTests) matrix-synapse; }; | ||
| 101 | passthru.plugins = plugins; | ||
| 102 | passthru.tools = tools; | ||
| 103 | passthru.python = python3; | ||
| 104 | |||
| 105 | meta = with lib; { | ||
| 106 | homepage = "https://matrix.org"; | ||
| 107 | description = "Matrix reference homeserver"; | ||
| 108 | license = licenses.asl20; | ||
| 109 | maintainers = teams.matrix.members; | ||
| 110 | }; | ||
| 111 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/plugins/default.nix b/overlays/matrix-synapse/1.70.1/plugins/default.nix deleted file mode 100644 index e67d9075..00000000 --- a/overlays/matrix-synapse/1.70.1/plugins/default.nix +++ /dev/null | |||
| @@ -1,8 +0,0 @@ | |||
| 1 | { callPackage }: | ||
| 2 | |||
| 3 | { | ||
| 4 | matrix-synapse-ldap3 = callPackage ./ldap3.nix { }; | ||
| 5 | matrix-synapse-mjolnir-antispam = callPackage ./mjolnir-antispam.nix { }; | ||
| 6 | matrix-synapse-pam = callPackage ./pam.nix { }; | ||
| 7 | matrix-synapse-shared-secret-auth = callPackage ./shared-secret-auth.nix { }; | ||
| 8 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/plugins/ldap3.nix b/overlays/matrix-synapse/1.70.1/plugins/ldap3.nix deleted file mode 100644 index 394c0f5e..00000000 --- a/overlays/matrix-synapse/1.70.1/plugins/ldap3.nix +++ /dev/null | |||
| @@ -1,17 +0,0 @@ | |||
| 1 | { isPy3k, buildPythonPackage, fetchPypi, service-identity, ldap3, twisted, ldaptor, mock }: | ||
| 2 | |||
| 3 | buildPythonPackage rec { | ||
| 4 | pname = "matrix-synapse-ldap3"; | ||
| 5 | version = "0.1.5"; | ||
| 6 | |||
| 7 | src = fetchPypi { | ||
| 8 | inherit pname version; | ||
| 9 | sha256 = "9fdf8df7c8ec756642aa0fea53b31c0b2f1924f70d7f049a2090b523125456fe"; | ||
| 10 | }; | ||
| 11 | |||
| 12 | propagatedBuildInputs = [ service-identity ldap3 twisted ]; | ||
| 13 | |||
| 14 | # ldaptor is not ready for py3 yet | ||
| 15 | doCheck = !isPy3k; | ||
| 16 | checkInputs = [ ldaptor mock ]; | ||
| 17 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/plugins/mjolnir-antispam.nix b/overlays/matrix-synapse/1.70.1/plugins/mjolnir-antispam.nix deleted file mode 100644 index 7372c2f7..00000000 --- a/overlays/matrix-synapse/1.70.1/plugins/mjolnir-antispam.nix +++ /dev/null | |||
| @@ -1,32 +0,0 @@ | |||
| 1 | { lib, buildPythonPackage, fetchFromGitHub, matrix-synapse }: | ||
| 2 | |||
| 3 | buildPythonPackage rec { | ||
| 4 | pname = "matrix-synapse-mjolnir-antispam"; | ||
| 5 | version = "1.5.0"; | ||
| 6 | |||
| 7 | src = fetchFromGitHub { | ||
| 8 | owner = "matrix-org"; | ||
| 9 | repo = "mjolnir"; | ||
| 10 | rev = "refs/tags/v${version}"; | ||
| 11 | sha256 = "sha256-YmP+r9W5e63Aw66lSQeTTbYwSF/vjPyHkoehJxtcRNw="; | ||
| 12 | }; | ||
| 13 | |||
| 14 | sourceRoot = "./source/synapse_antispam"; | ||
| 15 | |||
| 16 | propagatedBuildInputs = [ matrix-synapse ]; | ||
| 17 | |||
| 18 | doCheck = false; # no tests | ||
| 19 | pythonImportsCheck = [ "mjolnir" ]; | ||
| 20 | |||
| 21 | meta = with lib; { | ||
| 22 | description = "AntiSpam / Banlist plugin to be used with mjolnir"; | ||
| 23 | longDescription = '' | ||
| 24 | Primarily meant to block invites from undesired homeservers/users, | ||
| 25 | Mjolnir's Synapse module is a way to interpret ban lists and apply | ||
| 26 | them to your entire homeserver. | ||
| 27 | ''; | ||
| 28 | homepage = "https://github.com/matrix-org/mjolnir#synapse-module"; | ||
| 29 | license = licenses.asl20; | ||
| 30 | maintainers = with maintainers; [ jojosch ]; | ||
| 31 | }; | ||
| 32 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/plugins/pam.nix b/overlays/matrix-synapse/1.70.1/plugins/pam.nix deleted file mode 100644 index a14fe6d6..00000000 --- a/overlays/matrix-synapse/1.70.1/plugins/pam.nix +++ /dev/null | |||
| @@ -1,15 +0,0 @@ | |||
| 1 | { buildPythonPackage, fetchFromGitHub, twisted, python-pam }: | ||
| 2 | |||
| 3 | buildPythonPackage rec { | ||
| 4 | pname = "matrix-synapse-pam"; | ||
| 5 | version = "0.1.3"; | ||
| 6 | |||
| 7 | src = fetchFromGitHub { | ||
| 8 | owner = "14mRh4X0r"; | ||
| 9 | repo = "matrix-synapse-pam"; | ||
| 10 | rev = "v${version}"; | ||
| 11 | sha256 = "0jgz49cwiyih5cg3hr4byva04zjnq8aj7rima9874la9fc5sd2wf"; | ||
| 12 | }; | ||
| 13 | |||
| 14 | propagatedBuildInputs = [ twisted python-pam ]; | ||
| 15 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/plugins/shared-secret-auth.nix b/overlays/matrix-synapse/1.70.1/plugins/shared-secret-auth.nix deleted file mode 100644 index a6e22db3..00000000 --- a/overlays/matrix-synapse/1.70.1/plugins/shared-secret-auth.nix +++ /dev/null | |||
| @@ -1,26 +0,0 @@ | |||
| 1 | { lib, buildPythonPackage, fetchFromGitHub, matrix-synapse, twisted }: | ||
| 2 | |||
| 3 | buildPythonPackage rec { | ||
| 4 | pname = "matrix-synapse-shared-secret-auth"; | ||
| 5 | version = "2.0.2"; | ||
| 6 | |||
| 7 | src = fetchFromGitHub { | ||
| 8 | owner = "devture"; | ||
| 9 | repo = "matrix-synapse-shared-secret-auth"; | ||
| 10 | rev = version; | ||
| 11 | sha256 = "sha256-qzXKwTEOMtdvsxoU3Xh3vQyhK+Q18LfkeSts7EyDIXE="; | ||
| 12 | }; | ||
| 13 | |||
| 14 | doCheck = false; | ||
| 15 | pythonImportsCheck = [ "shared_secret_authenticator" ]; | ||
| 16 | |||
| 17 | buildInputs = [ matrix-synapse ]; | ||
| 18 | propagatedBuildInputs = [ twisted ]; | ||
| 19 | |||
| 20 | meta = with lib; { | ||
| 21 | description = "Shared Secret Authenticator password provider module for Matrix Synapse"; | ||
| 22 | homepage = "https://github.com/devture/matrix-synapse-shared-secret-auth"; | ||
| 23 | license = licenses.agpl3Plus; | ||
| 24 | maintainers = with maintainers; [ sumnerevans ]; | ||
| 25 | }; | ||
| 26 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/tools/default.nix b/overlays/matrix-synapse/1.70.1/tools/default.nix deleted file mode 100644 index defc35bc..00000000 --- a/overlays/matrix-synapse/1.70.1/tools/default.nix +++ /dev/null | |||
| @@ -1,6 +0,0 @@ | |||
| 1 | { callPackage }: | ||
| 2 | { | ||
| 3 | rust-synapse-compress-state = callPackage ./rust-synapse-compress-state.nix { }; | ||
| 4 | |||
| 5 | synadm = callPackage ./synadm.nix { }; | ||
| 6 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/tools/rust-synapse-compress-state.nix b/overlays/matrix-synapse/1.70.1/tools/rust-synapse-compress-state.nix deleted file mode 100644 index fcf123d6..00000000 --- a/overlays/matrix-synapse/1.70.1/tools/rust-synapse-compress-state.nix +++ /dev/null | |||
| @@ -1,30 +0,0 @@ | |||
| 1 | { lib, rustPlatform, python3, fetchFromGitHub, pkg-config, openssl }: | ||
| 2 | |||
| 3 | rustPlatform.buildRustPackage rec { | ||
| 4 | pname = "rust-synapse-compress-state"; | ||
| 5 | version = "0.1.3"; | ||
| 6 | |||
| 7 | src = fetchFromGitHub { | ||
| 8 | owner = "matrix-org"; | ||
| 9 | repo = pname; | ||
| 10 | rev = "v${version}"; | ||
| 11 | sha256 = "sha256-SSfVtG8kwHarVbB1O7xC2SSbUpPGYMHTMyoxu8mpEk0="; | ||
| 12 | }; | ||
| 13 | |||
| 14 | cargoSha256 = "sha256-PG+UeovhJMsIlm5dOYdtMxbUxZjwG3V59kAcB9aFP5c="; | ||
| 15 | |||
| 16 | cargoBuildFlags = [ | ||
| 17 | "--all" | ||
| 18 | ]; | ||
| 19 | |||
| 20 | nativeBuildInputs = [ python3 pkg-config ]; | ||
| 21 | |||
| 22 | buildInputs = [ openssl ]; | ||
| 23 | |||
| 24 | meta = with lib; { | ||
| 25 | description = "A tool to compress some state in a Synapse instance's database"; | ||
| 26 | homepage = "https://github.com/matrix-org/rust-synapse-compress-state"; | ||
| 27 | license = licenses.asl20; | ||
| 28 | maintainers = with maintainers; [ hexa maralorn ]; | ||
| 29 | }; | ||
| 30 | } | ||
diff --git a/overlays/matrix-synapse/1.70.1/tools/synadm.nix b/overlays/matrix-synapse/1.70.1/tools/synadm.nix deleted file mode 100644 index 5075e42e..00000000 --- a/overlays/matrix-synapse/1.70.1/tools/synadm.nix +++ /dev/null | |||
| @@ -1,47 +0,0 @@ | |||
| 1 | { lib | ||
| 2 | , python3Packages | ||
| 3 | }: | ||
| 4 | |||
| 5 | with python3Packages; buildPythonApplication rec { | ||
| 6 | pname = "synadm"; | ||
| 7 | version = "0.36"; | ||
| 8 | format = "setuptools"; | ||
| 9 | |||
| 10 | src = fetchPypi { | ||
| 11 | inherit pname version; | ||
| 12 | sha256 = "sha256-OMXUbfAC927qJw0B5sq1lGJQRkFAUdohIOkCYUbZumI="; | ||
| 13 | }; | ||
| 14 | |||
| 15 | postPatch = '' | ||
| 16 | substituteInPlace setup.py \ | ||
| 17 | --replace "Click>=7.0,<8.0" "Click" | ||
| 18 | ''; | ||
| 19 | |||
| 20 | propagatedBuildInputs = [ | ||
| 21 | click | ||
| 22 | click-option-group | ||
| 23 | dnspython | ||
| 24 | tabulate | ||
| 25 | pyyaml | ||
| 26 | requests | ||
| 27 | ]; | ||
| 28 | |||
| 29 | checkPhase = '' | ||
| 30 | runHook preCheck | ||
| 31 | export HOME=$TMPDIR | ||
| 32 | $out/bin/synadm -h > /dev/null | ||
| 33 | runHook postCheck | ||
| 34 | ''; | ||
| 35 | |||
| 36 | meta = with lib; { | ||
| 37 | description = "Command line admin tool for Synapse"; | ||
| 38 | longDescription = '' | ||
| 39 | A CLI tool to help admins of Matrix Synapse homeservers | ||
| 40 | conveniently issue commands available via its admin API's | ||
| 41 | (matrix-org/synapse@master/docs/admin_api) | ||
| 42 | ''; | ||
| 43 | homepage = "https://github.com/JOJ0/synadm"; | ||
| 44 | license = licenses.gpl3Plus; | ||
| 45 | maintainers = with maintainers; [ hexa ]; | ||
| 46 | }; | ||
| 47 | } | ||
diff --git a/overlays/matrix-synapse/default.nix b/overlays/matrix-synapse/default.nix deleted file mode 100644 index 9db73e35..00000000 --- a/overlays/matrix-synapse/default.nix +++ /dev/null | |||
| @@ -1,3 +0,0 @@ | |||
| 1 | { final, prev, ... }: { | ||
| 2 | matrix-synapse = final.callPackage ./1.70.1/default.nix {}; | ||
| 3 | } | ||
diff --git a/overlays/postfix-mta-sts-resolver.nix b/overlays/postfix-mta-sts-resolver.nix index d8b1ff00..22fc4118 100644 --- a/overlays/postfix-mta-sts-resolver.nix +++ b/overlays/postfix-mta-sts-resolver.nix | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | { | 2 | { |
| 3 | postfix-mta-sts-resolver = flakeInputs.mach-nix.lib.${final.system}.buildPythonPackage { | 3 | postfix-mta-sts-resolver = flakeInputs.mach-nix.lib.${final.system}.buildPythonPackage { |
| 4 | inherit (sources.postfix-mta-sts-resolver) src pname version; | 4 | inherit (sources.postfix-mta-sts-resolver) src pname version; |
| 5 | extras = "redis,uvloop"; | 5 | # extras = "redis,uvloop"; |
| 6 | ignoreDataOutdated = true; | 6 | ignoreDataOutdated = true; |
| 7 | 7 | ||
| 8 | requirements = '' | 8 | requirements = '' |
| @@ -13,17 +13,19 @@ | |||
| 13 | PyYAML>=3.12 | 13 | PyYAML>=3.12 |
| 14 | ''; | 14 | ''; |
| 15 | 15 | ||
| 16 | providers._default = "nixpkgs,sdist"; | 16 | providers.cffi = "nixpkgs"; |
| 17 | 17 | ||
| 18 | overridesPost = [ | 18 | # providers._default = "nixpkgs,sdist"; |
| 19 | (self: super: { | ||
| 20 | frozenlist = super.frozenlist.overrideAttrs (oldAttrs: { | ||
| 21 | nativeBuildInputs = (oldAttrs.nativeBuildInputs or []) ++ [ final.python310Packages.cython ]; | ||
| 22 | }); | ||
| 23 | }) | ||
| 24 | ]; | ||
| 25 | 19 | ||
| 26 | _.pyparsing.buildInputs.add = with final.python310Packages; [ flit-core ]; | 20 | # overridesPost = [ |
| 27 | _.idna.buildInputs.add = with final.python310Packages; [ flit-core ]; | 21 | # (self: super: { |
| 22 | # frozenlist = super.frozenlist.overrideAttrs (oldAttrs: { | ||
| 23 | # nativeBuildInputs = (oldAttrs.nativeBuildInputs or []) ++ [ final.python310Packages.cython ]; | ||
| 24 | # }); | ||
| 25 | # }) | ||
| 26 | # ]; | ||
| 27 | |||
| 28 | # _.pyparsing.buildInputs.add = with final.python310Packages; [ flit-core ]; | ||
| 29 | # _.idna.buildInputs.add = with final.python310Packages; [ flit-core ]; | ||
| 28 | }; | 30 | }; |
| 29 | } | 31 | } |
