ansible/templates/docker-compose-matrix.yml.j2
2019-11-28 02:09:17 +01:00

49 lines
1.6 KiB
Django/Jinja
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

version: '3'
services:
# matrix_synapse_version: "v1.5.1-py3"
# matrix_synapse_version: "v1.5.1"
#matrix_synapse_pg_host: synapse-postgres
synapse:
# build:
# context: ../..
# dockerfile: docker/Dockerfile
image: "matrixdotorg/synapse:{{ matrix_synapse_version }}"
# 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
environment:
- SYNAPSE_REPORT_STATS={{ matrix_synapse_report_stats }}
- SYNAPSE_CONFIG_PATH={{ matrix_synapse_config_docker_path }}
volumes:
# You may either store all the files in a local folder
- {{ matrix_synapse_config_dir }}:{{ matrix_synapse_config_docker_dir }}
- ./files:/data
# .. or you may split this between different storage points
# - ./files:/data
# - /path/to/ssd:/data/uploads
# - /path/to/large_hdd:/data/media
depends_on:
- db
# In order to expose Synapse, remove one of the following, you might for
# instance expose the TLS port directly:
ports:
- 8008:8008/tcp
# labels:
db:
image: docker.io/postgres:10-alpine
# Change that password, of course!
environment:
- POSTGRES_USER={{ matrix_synapse_db_name }}
- POSTGRES_PASSWORD={{ matrix_synapse_pg_pass }}
volumes:
# You may store the database tables in a local folder..
- ./schemas:/var/lib/postgresql/data
# .. or store them on some high performance storage for better results
# - /path/to/ssd/storage:/var/lib/postgresql/data