From c747964f3781c5f6423bb73c00c9512b656f0b25 Mon Sep 17 00:00:00 2001 From: Naoaki Ueda Date: Mon, 10 Oct 2022 18:12:19 +0900 Subject: Let the host-dir to manage the wp be a changeable --- docker-compose.yml | 4 ++-- dotenv.makefile.sample | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index efa1a2a..ddc409a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,7 +10,7 @@ services: ports: - 8000:80 volumes: - - ./html:/var/www/html + - ${WP_LOCAL_ROOT:-./html}:/var/www/html db: image: docker.io/library/mariadb:${MARIADB_VER:-latest} restart: always @@ -36,7 +36,7 @@ services: profiles: - cli volumes: - - ./html:/var/www/html + - ${WP_LOCAL_ROOT:-./html}:/var/www/html volumes: mariadb: diff --git a/dotenv.makefile.sample b/dotenv.makefile.sample index 44928d8..8acfed6 100644 --- a/dotenv.makefile.sample +++ b/dotenv.makefile.sample @@ -6,9 +6,13 @@ export MARIADB_VER := 10.3 export WP_IMAGE_TAG := php$(PHP_VER)-apache export WP_CLI_IMAGE_TAG := cli-php$(PHP_VER) +# HTML_DIR := html/www # WP_INSTALL_DIR := wp # WP_CONF := $(HTML_DIR)/$(WP_INSTALL_DIR)/wp-config.php +# To change host directory to manage wp +# export WP_LOCAL_ROOT := ./$(HTML_DIR) + # DOCKER = PODMAN SSH_REMOTE_HOST := example.com -- cgit v1.2.3-54-g00ecf