Parcourir la source

Merge pull request #157 from TheLastProject/feature/allow_disabling_url_previews

Add variable to disable homeserver url preview
pull/158/head
Slavi Pantaleev il y a 6 ans
committed by GitHub
Parent
révision
1495be1e0e
Aucune clé connue n'a été trouvée dans la base pour cette signature ID de la clé GPG: 4AEE18F83AFDEB23
2 fichiers modifiés avec 6 ajouts et 2 suppressions
  1. +4
    -0
      roles/matrix-synapse/defaults/main.yml
  2. +2
    -2
      roles/matrix-synapse/templates/synapse/homeserver.yaml.j2

+ 4
- 0
roles/matrix-synapse/defaults/main.yml Voir le fichier

@@ -167,6 +167,10 @@ matrix_synapse_password_providers_enabled: false
# to load message content directly from the homeserver. # to load message content directly from the homeserver.
matrix_synapse_push_include_content: true matrix_synapse_push_include_content: true


# If url previews should be generated. This will cause a request from Synapse to
# URLs shared by users.
matrix_synapse_url_preview_enabled: true

# Enable exposure of metrics to Prometheus # Enable exposure of metrics to Prometheus
# See https://github.com/matrix-org/synapse/blob/master/docs/metrics-howto.rst # See https://github.com/matrix-org/synapse/blob/master/docs/metrics-howto.rst
matrix_synapse_metrics_enabled: false matrix_synapse_metrics_enabled: false


+ 2
- 2
roles/matrix-synapse/templates/synapse/homeserver.yaml.j2 Voir le fichier

@@ -525,7 +525,7 @@ max_upload_size: "{{ matrix_synapse_max_upload_size_mb }}M"
# an explicit url_preview_ip_range_blacklist of IPs that the spider is # an explicit url_preview_ip_range_blacklist of IPs that the spider is
# denied from accessing. # denied from accessing.
# #
url_preview_enabled: true
url_preview_enabled: {{ matrix_synapse_url_preview_enabled|to_json }}


# List of IP address CIDR ranges that the URL preview spider is denied # List of IP address CIDR ranges that the URL preview spider is denied
# from accessing. There are no defaults: you must explicitly # from accessing. There are no defaults: you must explicitly
@@ -1169,4 +1169,4 @@ alias_creation_rules: {{ matrix_alias_creation_rules|to_json }}
# room_id: "*" # room_id: "*"
# action: allow # action: allow


room_list_publication_rules: {{ matrix_room_list_publication_rules|to_json }}
room_list_publication_rules: {{ matrix_room_list_publication_rules|to_json }}

Chargement…
Annuler
Enregistrer