version: '3.8'

services:
  mysql:
    image: mysql:8.0
    container_name: nex-mysql-test
    environment:
      MYSQL_ROOT_PASSWORD: testpass
      MYSQL_DATABASE: nex_test
      MYSQL_USER: nex_test
      MYSQL_PASSWORD: testpass
    ports:
      - "13306:3306"
    tmpfs:
      - /var/lib/mysql
    healthcheck:
      test: ["CMD", "mysqladmin", "ping", "-h", "localhost", "-u", "root", "-p$$MYSQL_ROOT_PASSWORD"]
      interval: 1s
      timeout: 5s
      retries: 10
      start_period: 10s
