diff --git a/conf/prometheus.yml b/conf/prometheus.yml index 6814b5f..a2f1fdc 100644 --- a/conf/prometheus.yml +++ b/conf/prometheus.yml @@ -26,6 +26,16 @@ scrape_configs: instance: "matrix.boba.best" job: "generic_worker" index: 2 + - targets: ["generic3:8008"] + labels: + instance: "matrix.boba.best" + job: "generic_worker" + index: 3 + - targets: ["generic4:8008"] + labels: + instance: "matrix.boba.best" + job: "generic_worker" + index: 4 - targets: ["sender1:8008"] labels: @@ -37,6 +47,16 @@ scrape_configs: instance: "matrix.boba.best" job: "federation_sender" index: 2 + - targets: ["sender3:8008"] + labels: + instance: "matrix.boba.best" + job: "federation_sender" + index: 3 + - targets: ["sender4:8008"] + labels: + instance: "matrix.boba.best" + job: "federation_sender" + index: 4 - targets: ["media:8008"] labels: diff --git a/docker-compose.yml b/docker-compose.yml index cd45b22..1056e70 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -78,6 +78,34 @@ services: healthcheck: disable: true + sender3: + image: matrixdotorg/synapse:$SYNAPSE_TAG + restart: always + command: ["run", "--config-path=/data/homeserver.yaml", "--config-path=/workers/replication.yaml", "--config-path=/workers/sender3.yaml"] + environment: + - SYNAPSE_WORKER=synapse.app.federation_sender + volumes: + - ./data/synapse:/data + - ./workers:/workers + depends_on: + - synapse + healthcheck: + disable: true + + sender4: + image: matrixdotorg/synapse:$SYNAPSE_TAG + restart: always + command: ["run", "--config-path=/data/homeserver.yaml", "--config-path=/workers/replication.yaml", "--config-path=/workers/sender4.yaml"] + environment: + - SYNAPSE_WORKER=synapse.app.federation_sender + volumes: + - ./data/synapse:/data + - ./workers:/workers + depends_on: + - synapse + healthcheck: + disable: true + media: image: matrixdotorg/synapse:$SYNAPSE_TAG restart: always @@ -126,6 +154,38 @@ services: labels: synapse-autoheal: "true" + generic3: + image: matrixdotorg/synapse:$SYNAPSE_TAG + restart: always + command: ["run", "--config-path=/data/homeserver.yaml", "--config-path=/workers/replication.yaml", "--config-path=/workers/generic.yaml"] + environment: + - SYNAPSE_WORKER=synapse.app.generic_worker + volumes: + - ./data/synapse:/data + - ./workers:/workers + depends_on: + - synapse + ports: + - 127.0.0.1:8012:8008/tcp + labels: + synapse-autoheal: "true" + + generic4: + image: matrixdotorg/synapse:$SYNAPSE_TAG + restart: always + command: ["run", "--config-path=/data/homeserver.yaml", "--config-path=/workers/replication.yaml", "--config-path=/workers/generic.yaml"] + environment: + - SYNAPSE_WORKER=synapse.app.generic_worker + volumes: + - ./data/synapse:/data + - ./workers:/workers + depends_on: + - synapse + ports: + - 127.0.0.1:8013:8008/tcp + labels: + synapse-autoheal: "true" + prometheus: image: prom/prometheus:latest restart: always diff --git a/workers/sender3.yaml b/workers/sender3.yaml new file mode 100644 index 0000000..52527b0 --- /dev/null +++ b/workers/sender3.yaml @@ -0,0 +1,10 @@ +worker_app: synapse.app.federation_sender +worker_name: sender3 + +worker_listeners: + - type: http + port: 8008 + x_forwarded: true + resources: + - names: + - metrics diff --git a/workers/sender4.yaml b/workers/sender4.yaml new file mode 100644 index 0000000..eee0b81 --- /dev/null +++ b/workers/sender4.yaml @@ -0,0 +1,10 @@ +worker_app: synapse.app.federation_sender +worker_name: sender4 + +worker_listeners: + - type: http + port: 8008 + x_forwarded: true + resources: + - names: + - metrics