mirror of https://gitlab.crans.org/nounous/nixos
Fix media + infiny loop with auth
parent
01557d89aa
commit
2a266f69e8
|
@ -55,13 +55,15 @@
|
|||
|
||||
report_stats = false;
|
||||
|
||||
public_baseurl = "https://matrix.crans.org/";
|
||||
|
||||
listeners = [
|
||||
{
|
||||
port = 8008;
|
||||
tls = false;
|
||||
bind_addresses = [
|
||||
"::"
|
||||
"0.0.0.0"
|
||||
"::1"
|
||||
"127.0.0.1"
|
||||
];
|
||||
type = "http";
|
||||
x_forwarded = true;
|
||||
|
@ -199,5 +201,17 @@
|
|||
proxy_set_header Host $host;
|
||||
'';
|
||||
};
|
||||
|
||||
locations."/media" = {
|
||||
proxyPass = "http://localhost:11111";
|
||||
extraConfig = ''
|
||||
rewrite ^/media(.*)$ $1 break;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header Host $host;
|
||||
'';
|
||||
};
|
||||
|
||||
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue