mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2025-10-21 11:48:55 +02:00
Run Synapse workers in their own containers
This switches the `docker exec` method of spawning Synapse workers inside the `matrix-synapse` container with dedicated containers for each worker. We also have dedicated systemd services for each worker, so this are now: - more consistent with everything else (we don't use systemd instantiated services anywhere) - we don't need the "parse systemd instance name into worker name + port" part - we don't need to keep track of PIDs manually - we don't need jq (less depenendencies) - workers dying would be restarted by systemd correctly, like any other service - `docker ps` shows each worker separately and we can observe resource usage
This commit is contained in:
@@ -2,6 +2,13 @@
|
||||
matrix_systemd_services_list: "{{ matrix_systemd_services_list + ['matrix-synapse.service'] }}"
|
||||
when: matrix_synapse_enabled|bool
|
||||
|
||||
- name: Ensure systemd services for workers are injected
|
||||
include_tasks: "{{ role_path }}/tasks/workers/util/inject_systemd_services_for_worker.yml"
|
||||
with_items: "{{ matrix_synapse_workers_enabled_list }}"
|
||||
loop_control:
|
||||
loop_var: matrix_synapse_worker_details
|
||||
when: matrix_synapse_enabled|bool and matrix_synapse_workers_enabled|bool
|
||||
|
||||
- set_fact:
|
||||
matrix_systemd_services_list: "{{ matrix_systemd_services_list + ['matrix-goofys.service'] }}"
|
||||
when: matrix_s3_media_store_enabled|bool
|
||||
|
Reference in New Issue
Block a user