networks: default: name: traefik_default external: true services: osp-app: depends_on: - osp-db - osp-redis container_name: osp-app entrypoint: ["/opt/osp/setup/docker/wait-for-it.sh", "osp-db:3306", "--strict", "-t", "60", "--", "/opt/osp/setup/docker/entrypoint.sh"] env_file: live.env environment: - DB_URL=mysql+pymysql://${MYSQL_USER}:${MYSQL_PASSWORD}@${MYSQL_HOST}:3306/${MYSQL_DATABASE} image: deamos/openstreamingplatform:latest labels: # Watchtower - "com.centurylinklabs.watchtower.enable=true" # Routes - "traefik.enable=true" - "traefik.http.routers.osp.entrypoints=websecure" - "traefik.http.routers.osp.rule=Host(`osp.${DOMAIN}`)" - "traefik.http.routers.osp.tls=true" - "traefik.http.routers.osp.tls.certresolver=myresolver" - "traefik.http.services.osp.loadbalancer.server.port=80" # RTMP specific - "traefik.tcp.routers.rtmpcast.entrypoints=rtmp" - "traefik.tcp.routers.rtmpcast.rule=HostSNI(`osp.${DOMAIN}`)" - "traefik.tcp.routers.rtmpcast.service=rtmpcast" - "traefik.tcp.routers.rtmpcast.tls=true" - "traefik.tcp.routers.rtmpcast.tls.certresolver=myresolver" - "traefik.tcp.services.rtmpcast.loadbalancer.server.port=1935" networks: - default restart: unless-stopped volumes: - ${OSP_ROOT}/data:/var/www - ${OSP_ROOT}/data/nginx/conf:/usr/local/nginx/conf osp-db: image: mariadb:10 container_name: osp-db command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW restart: unless-stopped env_file: live.env labels: # Watchtower - "com.centurylinklabs.watchtower.enable=true" networks: - default volumes: - /etc/localtime:/etc/localtime:ro - /etc/timezone:/etc/timezone:ro - ${OSP_ROOT}/db:/var/lib/mysql osp-redis: image: redis:6-alpine container_name: osp-redis command: redis-server --requirepass ${REDIS_HOST_PASSWORD} labels: - "com.centurylinklabs.watchtower.enable=true" networks: - default restart: unless-stopped volumes: - ${OSP_ROOT}/redis:/data - /etc/localtime:/etc/localtime:ro - /etc/timezone:/etc/timezone:ro