Skip to content

Commit

Permalink
feat: add mysql config dir volume (#113)
Browse files Browse the repository at this point in the history
  • Loading branch information
jippi authored Jan 24, 2025
1 parent 39acb2d commit a70948c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .env.docker
Original file line number Diff line number Diff line change
Expand Up @@ -1376,6 +1376,16 @@ DOCKER_DB_COMMAND="--default-authentication-plugin=mysql_native_password --old-m
# @dottie/validate required,dir
DOCKER_DB_HOST_DATA_PATH="${DOCKER_ALL_HOST_DATA_ROOT_PATH:?error}/db"

# Path (on host system) where the [db] container will store /etc/mysql/conf.d files
#
# Path is relative (./some/other/path) to the compose.yaml or absolute (/some/other/path)
#
# MySQL / MariaDB only - PostgreSQL store the config files in ${DOCKER_DB_HOST_DATA_PATH}
#
# @default ${DOCKER_ALL_HOST_CONFIG_ROOT_PATH}/db
# @dottie/validate required,dir
DOCKER_DB_HOST_CONFIG_PATH="${DOCKER_ALL_HOST_CONFIG_ROOT_PATH:?error}/db"

# Path (inside the container) where the [db] will store its data.
#
# Path MUST be absolute.
Expand Down
2 changes: 2 additions & 0 deletions compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,8 @@ services:
POSTGRES_DB: "${DB_DATABASE:?error}"
volumes:
- "${DOCKER_DB_HOST_DATA_PATH:?error}:${DOCKER_DB_CONTAINER_DATA_PATH:?error}"
# MySQL / MariaDB only
- "${DOCKER_DB_HOST_CONFIG_PATH:?error}:/etc/mysql/conf.d/"
ports:
- "${DOCKER_DB_HOST_PORT:?error}:${DOCKER_DB_CONTAINER_PORT:?error}"
healthcheck:
Expand Down

0 comments on commit a70948c

Please sign in to comment.