massicot: use conduit native well_known handler
This commit is contained in:
parent
3771134e3a
commit
d23748567b
3 changed files with 10 additions and 15 deletions
|
@ -158,11 +158,11 @@
|
|||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1716987116,
|
||||
"narHash": "sha256-uuEkErFVsFdg2K0cKbNQ9JlFSAm/xYqPr4rbPLI91Y8=",
|
||||
"lastModified": 1720515935,
|
||||
"narHash": "sha256-8b+fzR4W2hI5axwB+4nBwoA15awPKkck4ghhCt8v39M=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "8251761f93d6f5b91cee45ac09edb6e382641009",
|
||||
"rev": "a111ce6b537df12a39874aa9672caa87f8677eda",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
@ -80,7 +80,7 @@ in
|
|||
};
|
||||
|
||||
nix.settings = {
|
||||
trusted-users = config.users.groups.wheel.members ++ [ "root" ];
|
||||
trusted-users = [ "root" ];
|
||||
};
|
||||
|
||||
services.sing-box = let
|
||||
|
|
|
@ -85,6 +85,11 @@ in
|
|||
log = "info";
|
||||
database_backend = "rocksdb";
|
||||
allow_registration = false;
|
||||
|
||||
well_known = {
|
||||
client = "https://msg.xinyang.life";
|
||||
server = "msg.xinyang.life:443";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -160,17 +165,7 @@ in
|
|||
virtualHosts."xinyang.life:443".extraConfig = ''
|
||||
tls internal
|
||||
encode zstd gzip
|
||||
handle_path /.well-known/matrix/client {
|
||||
header Content-Type "application/json"
|
||||
header Access-Control-Allow-Origin "*"
|
||||
header Content-Disposition attachment; filename="client"
|
||||
respond `{"m.homeserver":{"base_url":"https://msg.xinyang.life/"}, "org.matrix.msc3575.proxy":{"url":"https://msg.xinyang.life/"}}`
|
||||
}
|
||||
handle_path /.well-known/matrix/server {
|
||||
header Content-Type "application/json"
|
||||
header Access-Control-Allow-Origin "*"
|
||||
respond `{"m.server": "msg.xinyang.life:443"}`
|
||||
}
|
||||
reverse_proxy /.well-known/matrix/* localhost:6167
|
||||
reverse_proxy * http://localhost:8080 {
|
||||
flush_interval -1
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue