# Copyright Broadcom, Inc. All Rights Reserved.
# SPDX-License-Identifier: APACHE-2.0

services:
  mysql:
    image: docker.io/bitnami/mysql:latest
    volumes:
      - 'mysql_data:/bitnami/mysql'
    environment:
      - ALLOW_EMPTY_PASSWORD=yes
      - MYSQL_USER=bn_wordpress
      - MYSQL_DATABASE=bitnami_wordpress
  wordpress:
    image: docker.io/bitnami/wordpress:6
    ports:
      - '80:8080'
      - '443:8443'
    volumes:
      - 'wordpress_data:/bitnami/wordpress'
    depends_on:
      - mysql
    environment:
      - ALLOW_EMPTY_PASSWORD=yes
      - WORDPRESS_DATABASE_HOST=mysql
      - WORDPRESS_DATABASE_PORT_NUMBER=3306
      - WORDPRESS_DATABASE_USER=bn_wordpress
      - WORDPRESS_DATABASE_NAME=bitnami_wordpress
volumes:
  mysql_data:
    driver: local
  wordpress_data:
    driver: local
