mirror of
https://github.com/matrix-org/dendrite.git
synced 2024-11-23 23:01:56 -06:00
Docker updates
This commit is contained in:
parent
b6827b68fb
commit
f22f649a05
|
@ -62,29 +62,28 @@ global:
|
||||||
- matrix.org
|
- matrix.org
|
||||||
- vector.im
|
- vector.im
|
||||||
|
|
||||||
# Configuration for Kafka/Naffka.
|
# Configuration for NATS JetStream
|
||||||
kafka:
|
jetstream:
|
||||||
# List of Kafka broker addresses to connect to. This is not needed if using
|
# A list of NATS Server addresses to connect to. If none are specified, an
|
||||||
# Naffka in monolith mode.
|
# internal NATS server will be started automatically when running Dendrite
|
||||||
|
# in monolith mode. It is required to specify the address of at least one
|
||||||
|
# NATS Server node if running in polylith mode.
|
||||||
addresses:
|
addresses:
|
||||||
- kafka:9092
|
- jetstream:4222
|
||||||
|
|
||||||
# The prefix to use for Kafka topic names for this homeserver. Change this only if
|
# Keep all NATS streams in memory, rather than persisting it to the storage
|
||||||
# you are running more than one Dendrite homeserver on the same Kafka deployment.
|
# path below. This option is present primarily for integration testing and
|
||||||
|
# should not be used on a real world Dendrite deployment.
|
||||||
|
in_memory: false
|
||||||
|
|
||||||
|
# Persistent directory to store JetStream streams in. This directory
|
||||||
|
# should be preserved across Dendrite restarts.
|
||||||
|
storage_path: ./
|
||||||
|
|
||||||
|
# The prefix to use for stream names for this homeserver - really only
|
||||||
|
# useful if running more than one Dendrite on the same NATS deployment.
|
||||||
topic_prefix: Dendrite
|
topic_prefix: Dendrite
|
||||||
|
|
||||||
# Whether to use Naffka instead of Kafka. This is only available in monolith
|
|
||||||
# mode, but means that you can run a single-process server without requiring
|
|
||||||
# Kafka.
|
|
||||||
use_naffka: false
|
|
||||||
|
|
||||||
# Naffka database options. Not required when using Kafka.
|
|
||||||
naffka_database:
|
|
||||||
connection_string: postgresql://dendrite:itsasecret@postgres/dendrite_naffka?sslmode=disable
|
|
||||||
max_open_conns: 10
|
|
||||||
max_idle_conns: 2
|
|
||||||
conn_max_lifetime: -1
|
|
||||||
|
|
||||||
# Configuration for Prometheus metric collection.
|
# Configuration for Prometheus metric collection.
|
||||||
metrics:
|
metrics:
|
||||||
# Whether or not Prometheus metrics are enabled.
|
# Whether or not Prometheus metrics are enabled.
|
|
@ -1,42 +0,0 @@
|
||||||
version: "3.4"
|
|
||||||
services:
|
|
||||||
# PostgreSQL is needed for both polylith and monolith modes.
|
|
||||||
postgres:
|
|
||||||
hostname: postgres
|
|
||||||
image: postgres:14
|
|
||||||
restart: always
|
|
||||||
volumes:
|
|
||||||
- ./postgres/create_db.sh:/docker-entrypoint-initdb.d/20-create_db.sh
|
|
||||||
# To persist your PostgreSQL databases outside of the Docker image, to
|
|
||||||
# prevent data loss, you will need to add something like this:
|
|
||||||
# - ./path/to/persistent/storage:/var/lib/postgresql/data
|
|
||||||
environment:
|
|
||||||
POSTGRES_PASSWORD: itsasecret
|
|
||||||
POSTGRES_USER: dendrite
|
|
||||||
networks:
|
|
||||||
- internal
|
|
||||||
|
|
||||||
# Zookeeper is only needed for polylith mode!
|
|
||||||
zookeeper:
|
|
||||||
hostname: zookeeper
|
|
||||||
image: zookeeper
|
|
||||||
networks:
|
|
||||||
- internal
|
|
||||||
|
|
||||||
# Kafka is only needed for polylith mode!
|
|
||||||
kafka:
|
|
||||||
container_name: dendrite_kafka
|
|
||||||
hostname: kafka
|
|
||||||
image: wurstmeister/kafka
|
|
||||||
environment:
|
|
||||||
KAFKA_ADVERTISED_HOST_NAME: "kafka"
|
|
||||||
KAFKA_DELETE_TOPIC_ENABLE: "true"
|
|
||||||
KAFKA_ZOOKEEPER_CONNECT: "zookeeper:2181"
|
|
||||||
depends_on:
|
|
||||||
- zookeeper
|
|
||||||
networks:
|
|
||||||
- internal
|
|
||||||
|
|
||||||
networks:
|
|
||||||
internal:
|
|
||||||
attachable: true
|
|
|
@ -1,5 +1,20 @@
|
||||||
version: "3.4"
|
version: "3.4"
|
||||||
services:
|
services:
|
||||||
|
postgres:
|
||||||
|
hostname: postgres
|
||||||
|
image: postgres:14
|
||||||
|
restart: always
|
||||||
|
volumes:
|
||||||
|
- ./postgres/create_db.sh:/docker-entrypoint-initdb.d/20-create_db.sh
|
||||||
|
# To persist your PostgreSQL databases outside of the Docker image,
|
||||||
|
# to prevent data loss, modify the following ./path_to path:
|
||||||
|
- ./path_to/postgresql:/var/lib/postgresql/data
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: itsasecret
|
||||||
|
POSTGRES_USER: dendrite
|
||||||
|
networks:
|
||||||
|
- internal
|
||||||
|
|
||||||
monolith:
|
monolith:
|
||||||
hostname: monolith
|
hostname: monolith
|
||||||
image: matrixdotorg/dendrite-monolith:latest
|
image: matrixdotorg/dendrite-monolith:latest
|
||||||
|
@ -13,6 +28,8 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
- ./media:/var/dendrite/media
|
- ./media:/var/dendrite/media
|
||||||
|
depends_on:
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,43 @@
|
||||||
version: "3.4"
|
version: "3.4"
|
||||||
services:
|
services:
|
||||||
|
postgres:
|
||||||
|
hostname: postgres
|
||||||
|
image: postgres:14
|
||||||
|
restart: always
|
||||||
|
volumes:
|
||||||
|
- ./postgres/create_db.sh:/docker-entrypoint-initdb.d/20-create_db.sh
|
||||||
|
# To persist your PostgreSQL databases outside of the Docker image,
|
||||||
|
# to prevent data loss, modify the following ./path_to path:
|
||||||
|
- ./path_to/postgresql:/var/lib/postgresql/data
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: itsasecret
|
||||||
|
POSTGRES_USER: dendrite
|
||||||
|
networks:
|
||||||
|
- internal
|
||||||
|
|
||||||
|
jetstream:
|
||||||
|
hostname: jetstream
|
||||||
|
image: nats:latest
|
||||||
|
command: |
|
||||||
|
--jetstream
|
||||||
|
--store_dir /var/lib/nats
|
||||||
|
--cluster_name Dendrite
|
||||||
|
volumes:
|
||||||
|
# To persist your NATS JetStream streams outside of the Docker image,
|
||||||
|
# prevent data loss, modify the following ./path_to path:
|
||||||
|
- ./path_to/nats:/var/lib/nats
|
||||||
|
networks:
|
||||||
|
- internal
|
||||||
|
|
||||||
client_api:
|
client_api:
|
||||||
hostname: client_api
|
hostname: client_api
|
||||||
image: matrixdotorg/dendrite-polylith:latest
|
image: matrixdotorg/dendrite-polylith:latest
|
||||||
command: clientapi
|
command: clientapi
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -25,6 +57,9 @@ services:
|
||||||
command: syncapi
|
command: syncapi
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -34,6 +69,9 @@ services:
|
||||||
command: roomserver
|
command: roomserver
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -43,6 +81,8 @@ services:
|
||||||
command: eduserver
|
command: eduserver
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -52,6 +92,9 @@ services:
|
||||||
command: federationapi
|
command: federationapi
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -61,6 +104,9 @@ services:
|
||||||
command: keyserver
|
command: keyserver
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -70,6 +116,9 @@ services:
|
||||||
command: userapi
|
command: userapi
|
||||||
volumes:
|
volumes:
|
||||||
- ./config:/etc/dendrite
|
- ./config:/etc/dendrite
|
||||||
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
|
|
||||||
|
@ -82,6 +131,8 @@ services:
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
depends_on:
|
depends_on:
|
||||||
|
- jetstream
|
||||||
|
- postgres
|
||||||
- room_server
|
- room_server
|
||||||
- user_api
|
- user_api
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue