version: '3'
services:
    db:
        image: mongo

    mailer:
        build: ../server
        volumes:
            - ../server/main.py:/usr/src/app/main.py
            - ./uwsgi:/tmp/uwsgi
        depends_on:
            - db
        environment:
            MONGODB_HOST: db
            SMTP_SERVER_ADDRESS: 'lol'
            SMTP_SERVER_PORT: 994
            SMTP_SERVER_USERNAME: toto
            SMTP_SERVER_PASSWORD: lol
            SMTP_SERVER_SENDER: moi
            ADMIN_PASSWORD: admin
            SMTP_SSL: 'true'

    proxy:
        image: nginx
        ports:
            - 8080:8080
        volumes:
            - ./nginx.conf:/etc/nginx.conf