mirror of
https://git.anonymousland.org/deathrow/synapse-docker-deployment.git
synced 2024-10-01 11:49:56 -04:00
31 lines
882 B
Plaintext
31 lines
882 B
Plaintext
# Choose sync worker based on the existence of "since" query parameter
|
|
map $arg_since $sync {
|
|
default sync_worker;
|
|
'' sync_init;
|
|
}
|
|
# Sync initial/normal
|
|
location ~ ^/_matrix/client/(r0|v3)/sync$ {
|
|
include snippets/matrix-proxy-headers.conf;
|
|
proxy_pass http://$sync;
|
|
proxy_read_timeout 1h;
|
|
}
|
|
|
|
# Normal sync
|
|
location ~ ^/_matrix/client/(api/v1|r0|v3)/events$ {
|
|
include snippets/matrix-proxy-headers.conf;
|
|
proxy_pass http://sync_worker;
|
|
}
|
|
|
|
# Initial_sync
|
|
location ~ ^/_matrix/client/(api/v1|r0|v3)/initialSync$ {
|
|
include snippets/matrix-proxy-headers.conf;
|
|
proxy_pass http://sync_init;
|
|
proxy_read_timeout 1h;
|
|
}
|
|
|
|
location ~ ^/_matrix/client/(api/v1|r0|v3)/rooms/[^/]+/initialSync$ {
|
|
include snippets/matrix-proxy-headers.conf;
|
|
proxy_pass http://sync_init;
|
|
proxy_read_timeout 1h;
|
|
}
|