dendrite/build/docker/docker-compose.polylith.yml

156 lines
3.4 KiB
YAML
Raw Normal View History

version: "3.4"
services:
2021-12-17 08:03:42 -06:00
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
2021-12-17 08:20:34 -06:00
healthcheck:
test: ["CMD-SHELL", "pg_isready -U dendrite"]
interval: 5s
timeout: 5s
retries: 5
2021-12-17 08:03:42 -06:00
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:
hostname: client_api
image: matrixdotorg/dendrite-polylith:latest
command: clientapi
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
media_api:
hostname: media_api
image: matrixdotorg/dendrite-polylith:latest
command: mediaapi
volumes:
- ./config:/etc/dendrite
- ./media:/var/dendrite/media
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
sync_api:
hostname: sync_api
image: matrixdotorg/dendrite-polylith:latest
command: syncapi
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
room_server:
hostname: room_server
image: matrixdotorg/dendrite-polylith:latest
command: roomserver
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
edu_server:
hostname: edu_server
image: matrixdotorg/dendrite-polylith:latest
command: eduserver
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
federation_api:
hostname: federation_api
image: matrixdotorg/dendrite-polylith:latest
command: federationapi
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
key_server:
hostname: key_server
image: matrixdotorg/dendrite-polylith:latest
command: keyserver
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
user_api:
hostname: user_api
image: matrixdotorg/dendrite-polylith:latest
command: userapi
volumes:
- ./config:/etc/dendrite
2021-12-17 08:03:42 -06:00
depends_on:
- jetstream
- postgres
networks:
- internal
2021-12-17 08:20:34 -06:00
restart: unless-stopped
appservice_api:
hostname: appservice_api
image: matrixdotorg/dendrite-polylith:latest
command: appservice
volumes:
- ./config:/etc/dendrite
networks:
- internal
depends_on:
2021-12-17 08:03:42 -06:00
- jetstream
- postgres
- room_server
- user_api
2021-12-17 08:20:34 -06:00
restart: unless-stopped
networks:
internal:
attachable: true