Bläddra i källkod

Add controls for influencing Matrix Synapse's rate-limiting

pull/6/head
Slavi Pantaleev 7 år sedan
förälder
incheckning
02d5b54fa5
3 ändrade filer med 25 tillägg och 3 borttagningar
  1. +19
    -1
      CHANGELOG.md
  2. +4
    -0
      roles/matrix-server/defaults/main.yml
  3. +2
    -2
      roles/matrix-server/templates/synapse/homeserver.yaml.j2

+ 19
- 1
CHANGELOG.md Visa fil

@@ -1,3 +1,21 @@
# 2018-08-20

## Matrix Synapse rate limit control variables

The following new variables can now be configured to control Matrix Synapse's rate-limiting (default values are shown below).

```yaml
matrix_synapse_rc_messages_per_second: 0.2
matrix_synapse_rc_message_burst_count: 10.0
```

## Shared Secret Auth support via matrix-synapse-shared-secret-auth

The playbook can now install and configure [matrix-synapse-shared-secret-auth](https://github.com/devture/matrix-synapse-shared-secret-auth) for you.

Additional details are available in [Setting up the Shared Secret Auth password provider module](configuring-playbook-shared-secret-auth.md).


# 2018-08-17 # 2018-08-17


## REST auth support via matrix-synapse-rest-auth ## REST auth support via matrix-synapse-rest-auth
@@ -71,4 +89,4 @@ The `setup-main` tag got renamed to `setup-all`.


## Docker container linking ## Docker container linking


Changed the way the Docker containers are linked together. The ones that need to communicate with others operate in a `matrix` network now and not in the default bridge network.
Changed the way the Docker containers are linked together. The ones that need to communicate with others operate in a `matrix` network now and not in the default bridge network.

+ 4
- 0
roles/matrix-server/defaults/main.yml Visa fil

@@ -61,6 +61,10 @@ matrix_synapse_max_upload_size_mb: 10
matrix_synapse_max_log_file_size_mb: 100 matrix_synapse_max_log_file_size_mb: 100
matrix_synapse_max_log_files_count: 10 matrix_synapse_max_log_files_count: 10


# Rate limits
matrix_synapse_rc_messages_per_second: 0.2
matrix_synapse_rc_message_burst_count: 10.0

# A list of additional "volumes" to mount in the container. # A list of additional "volumes" to mount in the container.
# This list gets populated dynamically based on Synapse extensions that have been enabled. # This list gets populated dynamically based on Synapse extensions that have been enabled.
# Contains definition objects like this: `{"src": "/outside", "dst": "/inside", "options": "rw|ro|slave|.."} # Contains definition objects like this: `{"src": "/outside", "dst": "/inside", "options": "rw|ro|slave|.."}


+ 2
- 2
roles/matrix-server/templates/synapse/homeserver.yaml.j2 Visa fil

@@ -197,10 +197,10 @@ log_config: "/data/{{ hostname_matrix }}.log.config"
## Ratelimiting ## ## Ratelimiting ##


# Number of messages a client can send per second # Number of messages a client can send per second
rc_messages_per_second: 0.2
rc_messages_per_second: {{ matrix_synapse_rc_messages_per_second }}


# Number of message a client can send before being throttled # Number of message a client can send before being throttled
rc_message_burst_count: 10.0
rc_message_burst_count: {{ matrix_synapse_rc_message_burst_count }}


# The federation window size in milliseconds # The federation window size in milliseconds
federation_rc_window_size: 1000 federation_rc_window_size: 1000


Laddar…
Avbryt
Spara