version: "3.9"
services:
  tdbimporter:
    container_name: tdbimporter_latest
    image: tdbimporter:latest
    restart: always
    build: .
    ports:
      - "3011:3011"
    depends_on:
      - redis_tdbimporter
      - mongo_tdbimporter
    environment:
      SENDERMAIL_HOST: "ssl0.ovh.net"
      SENDERMAIL_USER: "monitoring@thedigitalbox.com"
      SENDERMAIL_PASS: "Digital-2021"
      SENDERMAIL_TO: "dev@thedigitalbox.com"
    volumes:
      - ./logs:/code/logs
      - ./temp:/code/temp
    networks:
      - tdb-importer
  mongo_tdbimporter:
    container_name: tdbimporter_mongo
    image: mongo
    restart: always
    volumes:
      - ./mongodb_data:/data/db
    environment:
      MONGO_INITDB_ROOT_USERNAME: "CifkpX8SU4y8w0z5"
      MONGO_INITDB_ROOT_PASSWORD: "XzBdYQcA0u0i1Asw"
      TZ: "Europe/Rome"
    ports:
      - "27019:27017"
    networks:
      - tdb-importer
  redis_tdbimporter:
    container_name: tdbimporter_redis
    image: redis
    restart: always
    environment:
      TZ: "Europe/Rome"
    command: '--requirepass JvTFKJx60ER3twqJ --appendonly no --save ""'
    ports:
      - "6380:6379"
    networks:
      - tdb-importer
networks:
  tdb-importer:
