version: '2'
services:
    smart-farm-mysql:
        image: mysql:5.7.20
        volumes:
            - smart-farm-mysql:/var/lib/mysql/
        environment:
            - MYSQL_USER=root
            - MYSQL_ALLOW_EMPTY_PASSWORD=yes
            - MYSQL_DATABASE=smart_farm
        ports:
            - 3306:3306
        command: mysqld --lower_case_table_names=1 --skip-ssl --character_set_server=utf8mb4 --explicit_defaults_for_timestamp

volumes:
    smart-farm-mysql:
