summaryrefslogtreecommitdiff
path: root/hosts
diff options
context:
space:
mode:
Diffstat (limited to 'hosts')
-rw-r--r--hosts/surtr/matrix/default.nix15
1 files changed, 10 insertions, 5 deletions
diff --git a/hosts/surtr/matrix/default.nix b/hosts/surtr/matrix/default.nix
index 58ea04cb..ffaf6656 100644
--- a/hosts/surtr/matrix/default.nix
+++ b/hosts/surtr/matrix/default.nix
@@ -5,7 +5,7 @@
5 enable = true; 5 enable = true;
6 enable_metrics = true; 6 enable_metrics = true;
7 7
8 enable_registration = false; 8 enable_registration = true;
9 allow_guest_access = false; 9 allow_guest_access = false;
10 10
11 server_name = "synapse.li"; 11 server_name = "synapse.li";
@@ -14,10 +14,7 @@
14 { bind_address = "localhost"; 14 { bind_address = "localhost";
15 port = 8008; 15 port = 8008;
16 resources = [ 16 resources = [
17 { names = [ "client" ]; 17 { names = [ "client" "federation" ];
18 compress = true;
19 }
20 { names = [ "federation" ];
21 compress = false; 18 compress = false;
22 } 19 }
23 ]; 20 ];
@@ -38,6 +35,14 @@
38 "/run/credentials/matrix-synapse.service/registration.yaml" 35 "/run/credentials/matrix-synapse.service/registration.yaml"
39 "/run/credentials/matrix-synapse.service/turn-secret.yaml" 36 "/run/credentials/matrix-synapse.service/turn-secret.yaml"
40 ]; 37 ];
38 extraConfig = ''
39 refreshable_access_token_lifetime: 5m
40 nonrefreshable_access_token_lifetime: 24h
41 refresh_token_lifetime: 24h
42 registration_requires_token: true
43
44 admin_contact: 'mailto:matrix-admin@yggdrasil.li'
45 '';
41 }; 46 };
42 sops.secrets."matrix-synapse-registration.yaml" = { 47 sops.secrets."matrix-synapse-registration.yaml" = {
43 format = "binary"; 48 format = "binary";