mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2026-01-07 08:30:25 +00: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:
@@ -1,5 +1,19 @@
|
||||
---
|
||||
|
||||
# A previous version of the worker setup used this.
|
||||
# This is a temporary cleanup for people who ran that version.
|
||||
- name: Ensure old matrix-synapse.service.wants directory is gone
|
||||
file:
|
||||
path: "{{ matrix_systemd_path }}/matrix-synapse.service.wants"
|
||||
state: absent
|
||||
|
||||
# Same. This was part of a previous version of the worker setup.
|
||||
# No longer necessary.
|
||||
- name: Ensure matrix-synapse-worker-write-pid script is removed
|
||||
file:
|
||||
path: "{{ matrix_local_bin_path }}/matrix-synapse-worker-write-pid"
|
||||
state: absent
|
||||
|
||||
- include_tasks: "{{ role_path }}/tasks/workers/setup_install.yml"
|
||||
when: "matrix_synapse_enabled|bool and matrix_synapse_workers_enabled|bool"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user