From 7ffd75a5c7c143b4f5608a091a72771648746f73 Mon Sep 17 00:00:00 2001 From: Oanh Nguyen Date: Mon, 19 Feb 2024 09:13:34 +0700 Subject: [PATCH] Allow set Wordpress version and php version --- docker/wordpress/Dockerfile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docker/wordpress/Dockerfile b/docker/wordpress/Dockerfile index 2249179..6db0f92 100644 --- a/docker/wordpress/Dockerfile +++ b/docker/wordpress/Dockerfile @@ -1,10 +1,9 @@ ARG WORDPRESS_VERSION=6 ARG PHP_VERSION=8.2 -FROM wordpress:${WORDPRESS_VERSION}-php${PHP_VERSION}-fpm-alpine +FROM wordpress:cli-php${PHP_VERSION} AS cli -ARG WORDPRESS_VERSION -ARG PHP_VERSION +FROM wordpress:${WORDPRESS_VERSION}-php${PHP_VERSION}-fpm-alpine WORKDIR /var/www/html @@ -39,4 +38,4 @@ RUN apk add --update --no-cache \ ; # Install WP-CLI -COPY --from=wordpress:cli-php${PHP_VERSION} /usr/local/bin/wp /usr/local/bin/wp +COPY --from=cli /usr/local/bin/wp /usr/local/bin/wp