Skip to content

Commit

Permalink
Merge pull request #176 from MCubs/php-containers-update
Browse files Browse the repository at this point in the history
Update php containers: php73-rc to php73 release; add php74 support
  • Loading branch information
sokil committed Jun 23, 2020
2 parents 96d72b9 + d716174 commit b62b403
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 7 deletions.
15 changes: 14 additions & 1 deletion docker/compose.yml
Expand Up @@ -90,7 +90,7 @@ services:
RES_OPTIONS: "retrans:1 retry:1 timeout:1 attempts:1"

php73:
image: php:7.3-rc
image: php:7.3
container_name: phpmongo_php73
command: bash /phpmongo-source/docker/php/init.sh mongodb 1.5.3
volumes:
Expand All @@ -101,3 +101,16 @@ services:
PHP_IDE_CONFIG: "serverName=phpmongo"
XDEBUG_CONFIG: "idekey=PHPSTORM remote_autostart=1 remote_enable=1 remote_host=dockerhost remote_port=9001"
RES_OPTIONS: "retrans:1 retry:1 timeout:1 attempts:1"

php74:
image: php:7.4
container_name: phpmongo_php74
command: bash /phpmongo-source/docker/php/init.sh mongodb 1.5.3
volumes:
- ..:/phpmongo-source
- /phpmongo-source/vendor
- ./share:/share
environment:
PHP_IDE_CONFIG: "serverName=phpmongo"
XDEBUG_CONFIG: "idekey=PHPSTORM remote_autostart=1 remote_enable=1 remote_host=dockerhost remote_port=9001"
RES_OPTIONS: "retrans:1 retry:1 timeout:1 attempts:1"
5 changes: 2 additions & 3 deletions docker/php/init.sh
Expand Up @@ -61,10 +61,9 @@ then
echo "$DOCKERHOST_IP dockerhost" >> /etc/hosts

# last version of xdebug with support PHP < 7.0 is 2.5.5
if [[ ${PHP_VERSION:0:2} == "5." ]]; then
if [[ ${PHP_VERSION:0:2} == "5." ]];
then
pecl install xdebug-2.5.5;
elif [[ ${PHP_VERSION:0:3} == "7.3" ]]; then
pecl install xdebug-2.7.0beta1;
else
pecl install xdebug;
fi
Expand Down
6 changes: 3 additions & 3 deletions run-docker-tests.sh
Expand Up @@ -3,8 +3,8 @@
########################################################################################################################
# This script executed on host machine.
# You can optionally pass parameters:
# -p : version of PHP without dots. Currently supported 56, 70, 71
# -m : version of MongoDB without dots. Currently supported 24, 26, 30, 32, 33, 34
# -p : version of PHP without dots. Currently supported 56, 70, 71, 72, 73, 74
# -m : version of MongoDB without dots. Currently supported 24, 26, 30, 32, 33, 34, 36, 40, 41
# -t : path to concrete test file, relative to ./tests/
# For example:
# $ ./run-docker-tests.sh -p 56 -m 32 -t CursorTest.php
Expand Down Expand Up @@ -62,7 +62,7 @@ done
# if php versions not passed, fill default
if [[ -z $phpVersions ]]
then
phpVersions=("56" "70" "71" "72" "73")
phpVersions=("56" "70" "71" "72" "73" "74")
fi

# if versions not passed, fill default
Expand Down

0 comments on commit b62b403

Please sign in to comment.