From c65e1fd03995c05b4b1e6c4f467cd591b2c25cbe Mon Sep 17 00:00:00 2001 From: asus Date: Tue, 13 Feb 2024 22:09:51 +0100 Subject: [PATCH] - in notes : added duplicator infos - in wp dockerfil : added php7-session - in wp entrypoint : mv creation of plugins symlinks outside "if wp is installed" block --- notes.md | 4 ++++ srcs/requirements/wordpress/Dockerfile | 1 + srcs/requirements/wordpress/conf/wp_entrypoint.sh | 14 ++++++++------ 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/notes.md b/notes.md index 48849eb..d1bd314 100644 --- a/notes.md +++ b/notes.md @@ -4,6 +4,10 @@ - `docker exec -ti bash` to run bash inside a running container - `docker logs ` to see the logs on standard output of a container - `docker ps` to list the container, and see their names +- [duplicator](https://duplicator.com/knowledge-base/classic-install/) + in installer.php : + - delete first blank line + - close last line comment #### todo : diff --git a/srcs/requirements/wordpress/Dockerfile b/srcs/requirements/wordpress/Dockerfile index 1513d91..5b4ed1e 100644 --- a/srcs/requirements/wordpress/Dockerfile +++ b/srcs/requirements/wordpress/Dockerfile @@ -16,6 +16,7 @@ RUN apk update && apk add \ php7-zip \ php7-dom \ php7-curl \ + php7-session \ \ mariadb-client \ curl \ diff --git a/srcs/requirements/wordpress/conf/wp_entrypoint.sh b/srcs/requirements/wordpress/conf/wp_entrypoint.sh index f449642..06adb54 100644 --- a/srcs/requirements/wordpress/conf/wp_entrypoint.sh +++ b/srcs/requirements/wordpress/conf/wp_entrypoint.sh @@ -58,18 +58,20 @@ then chown -R www-data:www-data /var/www/* chmod 755 -R /var/www/* - echo -e ${YELLOW}plugins...${RESET} - plugins=$(ls ${WP_VOLUME_PLUGINS}) - for dir in $plugins; do - ln -s ${WP_VOLUME_PLUGINS}/$dir ${WP_VOLUME_DIR}/wp-content/plugins/$dir - done - echo -e ${GREEN}done !${RESET} else echo -e ${GREEN}wp is installed${RESET} fi +# installing plugins : +echo -e ${YELLOW}plugins...${RESET} +plugins=$(ls ${WP_VOLUME_PLUGINS}) +for dir in $plugins; do + echo -e ${YELLOW}"creating symlink : ln -s ${WP_VOLUME_PLUGINS}/$dir ${WP_VOLUME_DIR}/wp-content/plugins/"${RESET} + ln -s ${WP_VOLUME_PLUGINS}/$dir ${WP_VOLUME_DIR}/wp-content/plugins/ +done + # https://developer.wordpress.org/advanced-administration/debug/debug-wordpress/ echo -e ${YELLOW}configuring the error logs...${RESET} # Enable WP_DEBUG mode