version: "3.7"
services:
  web:
    build: .
    ports:
      - "${WEB_PORT}:3000"
    volumes:
      - ./content/files:${APP}/content/files
  mysql:
    image: "mysql:latest"
    environment:
      - MYSQL_USERNAME=${MYSQL_USERNAME}
      - MYSQL_PASSWORD=${MYSQL_PASSWORD}
      - MYSQL_DATABASE=${MYSQL_DATABASE}
    ports:
      - "${MYSQL_PORT}:3306"
    volumes:
      - ./content/db:/var/lib/mysql

version: "3.7"
services:
  web:
    build: .
    ports:
      - "${WEB_PORT}:3000"
    volumes:
      - ./content/files:${APP}/content/files
  mysql:
    image: "mysql:latest"
    environment:
      - MYSQL_RANDOM_ROOT_PASSWORD=true
      - MYSQL_USERNAME=${MYSQL_USERNAME}
      - MYSQL_PASSWORD=${MYSQL_PASSWORD}
      - MYSQL_DATABASE=${MYSQL_DATABASE}
    ports:
      - "${MYSQL_PORT}:3306"
    volumes:
      - ./content/db:/var/lib/mysql

Apply random root password in mysql docker
Apply random root password in mysql docker
