diff --git a/Dockerfile b/Dockerfile index 2c20fe2..a705db7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,17 +1,17 @@ -FROM php:7.2 +FROM php:7.4 ARG BUILD_DATE ARG VCS_REF ENV COMPOSER_ALLOW_SUPERUSER 1 LABEL Maintainer="Swiftmade <hello@swiftmade.co>" \ - Description="A simple PHP 7.2 image which contain just the minimum required to run Dusk on bitbucket pipelines." \ - org.label-schema.name="swiftmade/laravel-test-container:7.2" \ - org.label-schema.description="A simple PHP 7.2 image which contain just the minimum required to run Dusk on CI/CD pipelines." \ - org.label-schema.build-date=$BUILD_DATE \ - org.label-schema.vcs-url="https://github.com/swiftmade/laravel-test-container" \ - org.label-schema.vcs-ref=$VCS_REF \ - org.label-schema.schema-version="1.0.0" + Description="A simple PHP 7.4 image which contain just the minimum required to run Dusk on bitbucket pipelines." \ + org.label-schema.name="swiftmade/laravel-test-container:7.4" \ + org.label-schema.description="A simple PHP 7.4 image which contain just the minimum required to run Dusk on CI/CD pipelines." \ + org.label-schema.build-date=$BUILD_DATE \ + org.label-schema.vcs-url="https://github.com/swiftmade/laravel-test-container" \ + org.label-schema.vcs-ref=$VCS_REF \ + org.label-schema.schema-version="1.0.0" ENV COMPOSER_ALLOW_SUPERUSER 1 @@ -31,9 +31,11 @@ RUN docker-php-source extract \ && docker-php-source delete \ && docker-php-ext-configure pgsql -with-pgsql=/usr/local/pgsql \ && docker-php-ext-configure gd --with-jpeg \ - && docker-php-ext-install -j"$(nproc)" pdo pdo_mysql pdo_pgsql pgsql intl zip soap gd exif \ + && docker-php-ext-install -j"$(nproc)" pdo pdo_mysql pdo_pgsql pgsql intl zip soap gd exif bcmath \ && curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer \ && apt-get autoremove \ && rm -rf /var/lib/apt/lists/* -RUN Xvfb -ac :0 -screen 0 1280x1024x16 & \ No newline at end of file +RUN Xvfb -ac :0 -screen 0 1280x1024x16 & + +RUN echo 'memory_limit = 512M' >> /usr/local/etc/php/conf.d/docker-php-memlimit.ini; \ No newline at end of file diff --git a/README.md b/README.md index b890e6f..ebff158 100644 --- a/README.md +++ b/README.md @@ -1,19 +1,28 @@ -Laravel Test Container -====================== +# Laravel Test Container Use this docker image to run Laravel tests, including Dusk. ``` -swiftmade/laravel-test-container:7.2 +swiftmade/laravel-test-container:7.4 ``` -- 🐘 **PHP Version:** 7.2 +- 🐘 **PHP Version:** 7.4 - 🌍 **Chromium Version:** 80 -#### `php -m` output +#### What's inside? ``` +PHP 7.4.28 (cli) (built: Mar 29 2022 03:20:13) ( NTS ) +Copyright (c) The PHP Group +Zend Engine v3.4.0, Copyright (c) Zend Technologies + with Xdebug v3.1.4, Copyright (c) 2002-2022, by Derick Rethans + + +Composer version 2.3.3 2022-04-01 22:15:35 + + [PHP Modules] +bcmath Core ctype curl diff --git a/build-and-push.sh b/build-and-push.sh index 99db2f8..30f3097 100755 --- a/build-and-push.sh +++ b/build-and-push.sh @@ -1,4 +1,4 @@ #!/bin/sh -docker build . -t swiftmade/laravel-test-container:7.2 -docker push swiftmade/laravel-test-container:7.2 -docker run swiftmade/laravel-test-container:7.2 php -m \ No newline at end of file +docker build . -t swiftmade/laravel-test-container:7.4 +docker push swiftmade/laravel-test-container:7.4 +docker run --rm swiftmade/laravel-test-container:7.4 /bin/bash -c "php -v && echo $'\n' && composer --version && echo $'\n' && php -m" \ No newline at end of file