version: '3'

services:

    php:
        container_name: php
        build:
            context: .
            dockerfile: docker/Dockerfile
        volumes:
            - .:/code
        working_dir: /code
        command: docker/entrypoint.sh
        depends_on:
          - mysql
          - mongodb

    mysql:
        container_name: mysql
        image: mysql
        environment:
            MYSQL_ROOT_PASSWORD:
            MYSQL_DATABASE: unittest
            MYSQL_ALLOW_EMPTY_PASSWORD: 'yes'
        logging:
            driver: none

    mongodb:
        container_name: mongodb
        image: mongo
        logging:
            driver: none
