docker-compose.yml 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. version: "3"
  2. networks:
  3. web:
  4. external: true
  5. services:
  6. app:
  7. build:
  8. context: .
  9. dockerfile: Dockerfile.app
  10. restart: unless-stopped
  11. env_file:
  12. - .env
  13. environment:
  14. - SYNAPSE_SERVER_NAME=${SYNAPSE_SERVER_NAME}
  15. labels:
  16. traefik.enable: "true"
  17. traefik.frontend.rule: "Host: ${CHATONS_SERVICE:-matrix}.${CHATONS_DOMAIN:-localhost}, www.${CHATONS_SERVICE:-matrix}.${CHATONS_DOMAIN:-localhost}"
  18. networks:
  19. - web
  20. - default
  21. volumes:
  22. - ${CHATONS_ROOT_DIR:-/srv/chatons}/${CHATONS_SERVICE:-matrix}/data:/data
  23. ports:
  24. - 8448:8448
  25. db:
  26. image: postgres:10-alpine
  27. restart: unless-stopped
  28. env_file:
  29. - .env
  30. environment:
  31. - POSTGRES_USER=synapse
  32. - POSTGRES_DB=synapse
  33. volumes:
  34. - ${CHATONS_ROOT_DIR:-/srv/chatons}/${CHATONS_SERVICE:-matrix}/postgres:/var/lib/postgresql/data
  35. riot:
  36. build:
  37. context: .
  38. args:
  39. SYNAPSE_FULL_URL: ${CHATONS_SERVICE:-matrix}.${CHATONS_DOMAIN:-localhost}
  40. RIOT_VERSION: v1.0.3
  41. PROTOCOL: ${PROTOCOL:-http}
  42. restart: unless-stopped
  43. labels:
  44. traefik.enable: "true"
  45. traefik.frontend.rule: "Host: ${RIOT_SUBDOMAIN:-riot}.${CHATONS_DOMAIN:-localhost}, www.${RIOTSUBDOMAIN:-riot}.${CHATONS_DOMAIN:-localhost}"
  46. networks:
  47. - web