version: "3.7"

services:
  kinsobd-dev-db:
    image: mysql
    container_name: kinsobd-dev-db-mysql
    restart: on-failure
    environment:
      MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
      MYSQL_DATABASE: ${DB_NAME}
      MYSQL_USER: ${DB_USER}
      MYSQL_PASSWORD: ${DB_PASSWORD}
    volumes:
      - db_data:/var/lib/mysql
    ports:
      - ${DB_PORT}:3306
    command: --sql-mode="STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION"

# This is the part that was missing
volumes:
  db_data:
