Expose more of the API
This commit is contained in:
+14
-6
@@ -2,7 +2,7 @@
|
|||||||
# them by the following commands:
|
# them by the following commands:
|
||||||
# nix run nixpkgs.matrix-synapse
|
# nix run nixpkgs.matrix-synapse
|
||||||
# register_new_matrix_user -k "B9EoPr2WV9hzwc7uL2Sx1JmvCeKDEOGCpB0uginQcQtEH4wzRtkSIdo7lltrjSQa" http://localhost:8448
|
# register_new_matrix_user -k "B9EoPr2WV9hzwc7uL2Sx1JmvCeKDEOGCpB0uginQcQtEH4wzRtkSIdo7lltrjSQa" http://localhost:8448
|
||||||
{ config, ... }:
|
{ config, lib, ... }:
|
||||||
let
|
let
|
||||||
domain = "${config.networking.domain}";
|
domain = "${config.networking.domain}";
|
||||||
fqdn = "matrix.${domain}";
|
fqdn = "matrix.${domain}";
|
||||||
@@ -52,11 +52,19 @@ in
|
|||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
|
|
||||||
# Not the appropriate place for the chat client
|
# Not the appropriate place for the chat client
|
||||||
locations."/".extraConfig = "return 404;";
|
locations =
|
||||||
|
(builtins.listToAttrs (
|
||||||
locations."/_matrix" = {
|
builtins.map
|
||||||
proxyPass = "http://matrix.shire-zebra.ts.net:8448"; # Lacking the trailing / is correct
|
(val: lib.nameValuePair "/_${val}" { proxyPass = "http://matrix.shire-zebra.ts.net:8448"; })
|
||||||
};
|
[
|
||||||
|
"matrix"
|
||||||
|
"synapse"
|
||||||
|
"dendrite"
|
||||||
|
]
|
||||||
|
))
|
||||||
|
// {
|
||||||
|
"/".extraConfig = "return 404;";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user