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

78 lines
1.8 KiB
Django/Jinja

version: '3.1'
services:
synapse:
image: matrixdotorg/synapse:latest
restart: unless-stopped
logging:
driver: journald
volumes:
- synapse_data:/data
- ./homeserver.yaml:/data/homeserver.yaml:ro
- ./{{domain}}.log.config:/data/{{domain}}.log.config:ro
environment:
- SYNAPSE_SERVER_NAME={{domain}}
- SYNAPSE_REPORT_STATS=no
ports:
- "127.0.0.1:{{http_port}}:8008"
depends_on:
- database
database:
logging:
driver: journald
image: postgres:alpine
restart: unless-stopped
volumes:
- database:/var/lib/postgresql/data
environment:
- POSTGRES_DB=matrix
- POSTGRES_USER=matrix
- POSTGRES_PASSWORD={{matrix_database_password}}
- POSTGRES_INITDB_ARGS=--encoding=UTF8 --locale=C
healthcheck:
test: ["CMD-SHELL", "pg_isready -U matrix"]
interval: 10s
timeout: 5s
retries: 6
# 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:<version>
# restart: unless-stopped
# volumes:
# - whatsapp_bridge_data:/data
#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
volumes:
database:
synapse_data:
#telegram_bridge_data:
#whatsapp_bridge_data:
#facebook_bridge_data:
#instagram_bridge_data:
networks:
default:
driver: bridge