Skip to content

Commit 7e259bf

Browse files
committed
Adding the possibility for change easily the php version of the WP server
1 parent e7d4609 commit 7e259bf

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

docker-compose.yml

+6-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,12 @@ services:
1515
- wp_server
1616

1717
wp_server:
18-
build: ./docker-images/php/
18+
build:
19+
context: ./docker-images/php/
20+
args:
21+
PHP_VERSION: 7.1
22+
# PHP_VERSION: 7.0
23+
# PHP_VERSION: 5.6
1924
user: ${UID}:www-data
2025
container_name: wp_server
2126
volumes:

docker-images/php/Dockerfile

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
FROM php:7.1-fpm-alpine
1+
ARG PHP_VERSION
2+
3+
FROM php:"$PHP_VERSION"-fpm-alpine
24

35
# docker-entrypoint.sh dependencies
46
RUN apk add --no-cache \

0 commit comments

Comments
 (0)