docker-compose-configs/synapse/docker-compose.yml

110 lines
3.2 KiB
YAML
Raw Normal View History

2024-09-03 23:02:49 -04:00
# This compose file is compatible with Compose itself, it might need some
# adjustments to run properly with stack.
services:
synapse:
build:
context: .
dockerfile: Dockerfile
2024-09-03 23:43:12 -04:00
container_name: synapse
2024-09-03 23:02:49 -04:00
image: docker.io/matrixdotorg/synapse:latest
# Since synapse does not retry to connect to the database, restart upon
# failure
restart: unless-stopped
# See the readme for a full documentation of the environment settings
# NOTE: You must edit homeserver.yaml to use postgres, it defaults to sqlite
environment:
- SYNAPSE_CONFIG_PATH=/data/homeserver.yaml
- SYNAPSE_SERVER_NAME=nadeko.net
- SYNAPSE_REPORT_STATS=no
volumes:
# You may either store all the files in a local folder
- ./synapse_data:/data:rw
- ./synapse_data/homeserver.yaml:/data/homeserver.yaml:ro
- /var/run/postgresql/:/run/postgresql:rw
# .. or you may split this between different storage points
# - ./files:/data
# - /path/to/ssd:/data/uploads
# - /path/to/large_hdd:/data/media
# In order to expose Synapse, remove one of the following, you might for
# instance expose the TLS port directly:
ports:
2024-11-27 23:42:48 -03:00
- 127.0.0.1:10022:8008/tcp
- 127.0.0.1:9183:9183/tcp
2024-09-03 23:02:49 -04:00
healthcheck:
test: ["CMD", "curl", "-fSs", "http://localhost:8008/health"]
interval: 15s
timeout: 5s
retries: 3
start_period: 5s
2024-11-27 23:42:48 -03:00
# sliding-sync:
# image: ghcr.io/matrix-org/sliding-sync:latest
# container_name: matrix-sliding-sync
# restart: unless-stopped
# volumes:
# - /var/run/postgresql/:/run/postgresql:rw
# env_file:
# - path: ./sliding-sync/.env
# required: true
# environment:
# - SYNCV3_SERVER=http://synapse:8008
# - SYNCV3_BINDADDR=:8008
# - SYNCV3_LOG_LEVEL=debug
# ports:
# - 127.0.0.1:10024:8008
# depends_on:
# - synapse
# matrix-auth-service:
# image: ghcr.io/element-hq/matrix-authentication-service:latest
# container_name: matrix-authentication-service
# restart: unless-stopped
# volumes:
# - /var/run/postgresql/:/run/postgresql:rw
# - ./matrix-auth-service/config.yaml:/config.yaml:rw
# ports:
# - 127.0.0.1:10026:8080
# depends_on:
# - synapse
2024-09-03 23:02:49 -04:00
mautrix-telegram:
image: dock.mau.dev/mautrix/telegram:latest
2024-09-03 23:43:12 -04:00
container_name: mautrix-telegram
2024-09-03 23:02:49 -04:00
restart: unless-stopped
volumes:
- ./mautrix-telegram_data:/data:z
- /var/run/postgresql/:/run/postgresql:rw
depends_on:
- synapse
mautrix-whatsapp:
image: dock.mau.dev/mautrix/whatsapp:latest
2024-09-03 23:43:12 -04:00
container_name: mautrix-whatsapp
2024-09-03 23:02:49 -04:00
restart: unless-stopped
volumes:
- ./mautrix-whatsapp_data:/data:z
- /var/run/postgresql/:/run/postgresql:rw
depends_on:
- synapse
element:
image: vectorim/element-web:latest
2024-09-03 23:43:12 -04:00
container_name: matrix-element
2024-09-03 23:02:49 -04:00
restart: unless-stopped
volumes:
- ./element-web/config.json:/app/config.json:ro
ports:
- 10023:80/tcp
2024-11-27 23:42:48 -03:00
synapse-admin:
image: awesometechnologies/synapse-admin
ports:
- "10025:80"
restart: unless-stopped
2024-09-03 23:02:49 -04:00
# TODO: Use pgbouncer
networks:
default:
name: synapse