diff --git a/modules/services/server/matrix.nix b/modules/services/server/matrix.nix index 5b0b388..868a2c7 100644 --- a/modules/services/server/matrix.nix +++ b/modules/services/server/matrix.nix @@ -83,37 +83,6 @@ in { }; }; - users = { - users = { - mautrix-whatsapp = { - uid = 3001; - group = "mautrix-whatsapp"; - isSystemUser = true; - }; - mautrix-telegram = { - uid = 3002; - group = "mautrix-telegram"; - isSystemUser = true; - }; - mautrix-signal = { - uid = 3003; - group = "mautrix-signal"; - isSystemUser = true; - }; - }; - groups = { - mautrix-whatsapp = { - gid = 3001; - }; - mautrix-telegram = { - gid = 3002; - }; - mautrix-signal = { - gid = 3003; - }; - }; - }; - services = { mautrix-telegram = { enable = true; @@ -185,6 +154,8 @@ in { appservice = { hostname = "127.0.0.1"; id = "signal"; + as_token = "$MAUTRIX_SIGNAL_AS_TOKEN"; + hs_token = "$MAUTRIX_SIGNAL_HS_TOKEN"; }; database = { type = "postgres"; @@ -230,11 +201,13 @@ in { appservice = { hostname = "127.0.0.1"; id = "whatsapp"; + as_token = "$MAUTRIX_WHATSAPP_AS_TOKEN"; + hs_token = "$MAUTRIX_WHATSAPP_HS_TOKEN"; + database = { + type = "postgres"; + uri = "$MAUTRIX_WHATSAPP_APPSERVICE_DATABASE"; + }; }; - database = { - type = "postgres"; - uri = "$MAUTRIX_WHATSAPP_APPSERVICE_DATABASE"; - }; encryption = { allow = true; default = true; @@ -244,27 +217,24 @@ in { }; pickle_key = "$MAUTRIX_WHATSAPP_ENCRYPTION_PICKLE_KEY"; }; - network = { - history_sync = { - request_full_sync = true; - }; - }; - backfill = { - enabled = true; - }; bridge = { + history_sync.request_full_sync = true; + encryption = { + allow = true; + default = true; + verification_levels = { + receive = "cross-signed-untrusted"; + send = "cross-signed-untrusted"; + }; + pickle_key = "$MAUTRIX_WHATSAPP_ENCRYPTION_PICKLE_KEY"; + }; + private_chat_portal_meta = true; permissions = { "@kabbone:kabtop.de" = "admin"; }; }; logging = { min_level = "warn"; - writers = [ - { - format = "pretty-colored"; - type = "stdout"; - } - ]; }; }; }; diff --git a/secrets/services/matrix/mautrix-signal.age b/secrets/services/matrix/mautrix-signal.age index 6690c12..2bf97ac 100644 Binary files a/secrets/services/matrix/mautrix-signal.age and b/secrets/services/matrix/mautrix-signal.age differ diff --git a/secrets/services/matrix/mautrix-whatsapp.age b/secrets/services/matrix/mautrix-whatsapp.age index 8cd256f..3598cc3 100644 Binary files a/secrets/services/matrix/mautrix-whatsapp.age and b/secrets/services/matrix/mautrix-whatsapp.age differ