computer-playbook/roles/docker-matrix/templates/docker-compose.yml.j2

84 lines
2.0 KiB
Plaintext
Raw Normal View History

2023-12-12 22:36:35 +01:00
version: '3.1'
services:
2023-12-13 08:58:53 +01:00
synapse:
2023-12-12 22:36:35 +01:00
image: matrixdotorg/synapse:latest
restart: always
2023-12-12 22:36:35 +01:00
logging:
driver: journald
volumes:
2023-12-13 08:58:53 +01:00
- synapse_data:/data
2023-12-12 22:36:35 +01:00
- ./homeserver.yaml:/data/homeserver.yaml:ro
2023-12-19 14:07:05 +01:00
- ./{{synapse_domain}}.log.config:/data/{{synapse_domain}}.log.config:ro
2023-12-12 22:36:35 +01:00
environment:
2023-12-19 14:07:05 +01:00
- SYNAPSE_SERVER_NAME={{synapse_domain}}
2023-12-12 22:36:35 +01:00
- SYNAPSE_REPORT_STATS=no
ports:
2023-12-19 14:07:05 +01:00
- "127.0.0.1:{{synapse_http_port}}:8008"
2023-12-12 22:36:35 +01:00
depends_on:
- database
database:
logging:
driver: journald
2023-12-19 10:00:16 +01:00
image: postgres:16
restart: unless-stopped
volumes:
2023-12-19 10:00:16 +01:00
- database:/var/lib/postgresql/data
environment:
- POSTGRES_DB=matrix
- POSTGRES_USER=matrix
- POSTGRES_PASSWORD={{matrix_database_password}}
- POSTGRES_INITDB_ARGS=--encoding=UTF8 --locale=C
2023-12-12 22:36:35 +01:00
healthcheck:
2023-12-19 10:00:16 +01:00
test: ["CMD-SHELL", "pg_isready -U matrix"]
interval: 10s
timeout: 5s
retries: 6
2023-12-19 14:07:05 +01:00
element:
image: vectorim/element-web:latest
restart: unless-stopped
volumes:
- ./element-config.json:/app/config.json
ports:
- "127.0.0.1:{{element_http_port}}:80"
2023-12-12 22:36:35 +01:00
2023-12-13 08:58:53 +01:00
# bridges
#mautrix-telegram:
# container_name: mautrix-telegram
# image: dock.mau.dev/mautrix/telegram:<version>
# restart: unless-stopped
# volumes:
# - telegram_bridge_data:/data
#mautrix-whatsapp:
# container_name: mautrix-whatsapp
# image: dock.mau.dev/mautrix/whatsapp:latest
2023-12-13 08:58:53 +01:00
# restart: unless-stopped
# volumes:
# - ./mautrix_whatsapp:/data
2023-12-13 08:58:53 +01:00
#mautrix-facebook:
# container_name: mautrix-facebook
# image: dock.mau.dev/mautrix/facebook:<version>
# restart: unless-stopped
# volumes:
# - facebook_bridge_data:/data
#mautrix-instagram:
# container_name: mautrix-instagram
# image: dock.mau.dev/mautrix/instagram:<version>
# restart: unless-stopped
# volumes:
# - instagram_bridge_data:/data
2023-12-12 22:36:35 +01:00
volumes:
database:
2023-12-13 08:58:53 +01:00
synapse_data:
#telegram_bridge_data:
#whatsapp_bridge_data:
#facebook_bridge_data:
#instagram_bridge_data:
2023-12-12 22:36:35 +01:00
networks:
default:
driver: bridge