mautrix-telegram: add inputs for E2BE support (#132979)

https://docs.mau.fi/bridges/general/end-to-bridge-encryption.html
This commit is contained in:
Yuka 2021-08-07 12:38:46 +02:00 committed by GitHub
parent 3f3e2da660
commit f1d1ed4f02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,6 @@
{ lib, python3, mautrix-telegram, fetchFromGitHub }:
{ lib, python3, mautrix-telegram, fetchFromGitHub
, withE2BE ? true
}:
let
python = python3.override {
@ -36,7 +38,7 @@ in python.pkgs.buildPythonPackage rec {
sed -i -e '/alembic>/d' requirements.txt
'';
propagatedBuildInputs = with python.pkgs; [
propagatedBuildInputs = with python.pkgs; ([
Mako
aiohttp
mautrix
@ -49,7 +51,12 @@ in python.pkgs.buildPythonPackage rec {
pillow
lxml
setuptools
] ++ dbDrivers;
] ++ lib.optionals withE2BE [
asyncpg
python-olm
pycryptodome
unpaddedbase64
]) ++ dbDrivers;
# `alembic` (a database migration tool) is only needed for the initial setup,
# and not needed during the actual runtime. However `alembic` requires `mautrix-telegram`