diff --git a/.github/workflows/build-nginx-1-24.yml b/.github/workflows/build-nginx-1-24.yml index 7059da327..7d1cadb16 100644 --- a/.github/workflows/build-nginx-1-24.yml +++ b/.github/workflows/build-nginx-1-24.yml @@ -33,4 +33,4 @@ jobs: push: true tags: | markoshust/magento-nginx:1.24 - markoshust/magento-nginx:1.24-0 + markoshust/magento-nginx:1.24-1 diff --git a/.github/workflows/build-php-8-1.yml b/.github/workflows/build-php-8-1.yml index 0371e32bf..e94c4505f 100644 --- a/.github/workflows/build-php-8-1.yml +++ b/.github/workflows/build-php-8-1.yml @@ -33,4 +33,4 @@ jobs: push: true tags: | markoshust/magento-php:8.1-fpm - markoshust/magento-php:8.1-fpm-7 + markoshust/magento-php:8.1-fpm-8 diff --git a/.github/workflows/build-php-8-2.yml b/.github/workflows/build-php-8-2.yml index 3331db835..f8b2a1ead 100644 --- a/.github/workflows/build-php-8-2.yml +++ b/.github/workflows/build-php-8-2.yml @@ -33,4 +33,4 @@ jobs: push: true tags: | markoshust/magento-php:8.2-fpm - markoshust/magento-php:8.2-fpm-6 + markoshust/magento-php:8.2-fpm-7 diff --git a/.github/workflows/build-php-8-3.yml b/.github/workflows/build-php-8-3.yml index 53b183fa9..61501b2e3 100644 --- a/.github/workflows/build-php-8-3.yml +++ b/.github/workflows/build-php-8-3.yml @@ -33,4 +33,4 @@ jobs: push: true tags: | markoshust/magento-php:8.3-fpm - markoshust/magento-php:8.3-fpm-4 + markoshust/magento-php:8.3-fpm-5 diff --git a/.github/workflows/build-php-8-4.yml b/.github/workflows/build-php-8-4.yml index 271afdfd1..d606b559e 100644 --- a/.github/workflows/build-php-8-4.yml +++ b/.github/workflows/build-php-8-4.yml @@ -32,4 +32,4 @@ jobs: platforms: linux/amd64,linux/arm64 push: true tags: | - markoshust/magento-php:8.4-fpm-dev + markoshust/magento-php:8.4-fpm-0 diff --git a/CHANGELOG.md b/CHANGELOG.md index 3d651e378..2c3c0d07a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,32 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [51.0.0] - 2025-04-08 + +This release provides full support for Magento 2.4.8 (released same day), includes multiple Docker image updates, fixes important bugs, and adds several new utilities for improved developer experience. + +### Added +- New `bin/docker-start` helper script to automatically start Docker Desktop or OrbStack environments [PR #956](https://github.com/markshust/docker-magento/pull/956) +- Enhanced cron management that maintains state between container restarts [PR #1309](https://github.com/markshust/docker-magento/pull/1309) +- Compatibility settings for Elasticsearch and OpenSearch on ARM64/Apple M-series chips [PR #1307](https://github.com/markshust/docker-magento/pull/1307) +- Relocated Selenium service configuration to `compose.dev.yaml` for better organization [PR #913](https://github.com/markshust/docker-magento/pull/913) +- Firefox Developer Edition support for SSL certificates [PR #830](https://github.com/markshust/docker-magento/pull/830) + +### Updated +- Upgraded Node.js to version 22.x across all PHP images [PR #1305](https://github.com/markshust/docker-magento/pull/1305) +- Upgraded PHP extensions: Redis to 6.2.0, Swoole to 6.0.2, Xdebug to 3.4.2 [PR #1305](https://github.com/markshust/docker-magento/pull/1305) +- Updated Composer to 2.8.6 in PHP 8.2, 8.3, and 8.4 images [PR #1305](https://github.com/markshust/docker-magento/pull/1305) +- Updated SPX PHP profiler to version 0.4.18 [PR #1305](https://github.com/markshust/docker-magento/pull/1305) +- Increased client max body size limit to 100M in nginx configuration [PR #1307](https://github.com/markshust/docker-magento/pull/1307) +- Improved SSL certificate handling for multi-domain setups [PR #1300](https://github.com/markshust/docker-magento/pull/1300) + +### Fixed +- OpenSearch and Elasticsearch container failures on ARM64/Apple Silicon devices [PR #1307](https://github.com/markshust/docker-magento/pull/1307) +- Cron service unexpectedly failing to restart after being enabled [PR #1309](https://github.com/markshust/docker-magento/pull/1309) +- Multiple domain support in SSL certificate generation [PR #1257](https://github.com/markshust/docker-magento/pull/1257) +- Typo in README documentation [PR #1296](https://github.com/markshust/docker-magento/pull/1296) +- Reorganized backend access documentation for better visibility [PR #1306](https://github.com/markshust/docker-magento/pull/1306) + ## [50.0.0] - 2024-01-31 ### Added diff --git a/README.md b/README.md index 208230403..78c05da24 100644 --- a/README.md +++ b/README.md @@ -151,28 +151,13 @@ mkdir -p ~/Sites/magento cd $_ # Run this automated one-liner from the directory you want to install your project. -curl -s https://raw.githubusercontent.com/markshust/docker-magento/master/lib/onelinesetup | bash -s -- magento.test community 2.4.7-p3 +curl -s https://raw.githubusercontent.com/markshust/docker-magento/master/lib/onelinesetup | bash -s -- magento.test community 2.4.8 ``` -The `magento.test` above defines the hostname to use, `community` is the Magento edition, and the `2.4.7-p3` defines the Magento version to install. Note that since we need a write to `/etc/hosts` for DNS resolution, you will be prompted for your system password during setup. +The `magento.test` above defines the hostname to use, `community` is the Magento edition, and the `2.4.8` defines the Magento version to install. Note that since we need a write to `/etc/hosts` for DNS resolution, you will be prompted for your system password during setup. After the one-liner above completes running, you should be able to access your site at `https://magento.test`. -## Accessing the Magento Backend - -After successfully installing the Magento environment, you can access the backend by following these steps: - -1. Open your web browser and go to the following URL: `https://magento.test/admin/`. - -2. Use the following default credentials to log in: -- **Username:** `john.smith` -- **Password:** `password123` - -3. Upon logging in, you might be prompted to configure Two-Factor Authentication (2FA). This emails you a code to log in with (which you can check with Mailcatcher by visiting `http://{yourdomain}:1080`). By default, the email address used for this purpose is: -- **Email:** `john.smith@gmail.com` - -If you are testing in a local development environment and wish to disable 2FA, you can do so by installing [Mark's DisableTwoFactorAuth module](https://github.com/markshust/magento2-module-disabletwofactorauth). - #### Install sample data After the above installation is complete, run the following lines to install sample data: @@ -197,7 +182,7 @@ cd $_ curl -s https://raw.githubusercontent.com/markshust/docker-magento/master/lib/template | bash # Download the version of Magento you want to use with: -bin/download community 2.4.7-p3 +bin/download community 2.4.8 # You can specify the edition (community, enterprise, mageos) and version (2.4.7-p3, 1.0.5, etc.) # If no arguments are passed in, the edition defaults to "community" # If no version is specified, it defaults to the most recent version defined in `bin/download` @@ -209,17 +194,6 @@ bin/download community 2.4.7-p3 # bin/cli git checkout 2.4-develop # bin/composer install -# Want to install Magento <2.4.6? In bin/setup-install, replace the lines: -# --elasticsearch-host="$ES_HOST" \ -# --elasticsearch-port="$ES_PORT" \ -# --opensearch-host="$OPENSEARCH_HOST" \ -# --opensearch-port="$OPENSEARCH_PORT" \ -# --search-engine=opensearch \ -# with: -# --elasticsearch-host="$ES_HOST" \ -# --elasticsearch-port="$ES_PORT" \ -# --search-engine=elasticsearch7 \ - # Run the setup installer for Magento: bin/setup magento.test @@ -321,8 +295,9 @@ It is recommended to keep your root docker config files in one repository, and y - `bin/dev-urn-catalog-generate`: Generate URN's for PhpStorm and remap paths to local host. Restart PhpStorm after running this command. - `bin/devconsole`: Alias for `bin/n98-magerun2 dev:console` - `bin/docker-compose`: Support V1 (`docker-compose`) and V2 (`docker compose`) docker compose command, and use custom configuration files, such as `compose.yml` and `compose.dev.yml` +- `bin/docker-start`: Start the Docker application (either Orbstack or Docker Desktop) - `bin/docker-stats`: Display container name and container ID, status for CPU, memory usage(in MiB and %), and memory limit of currently-running Docker containers. -- `bin/download`: Download specific Magento version from Composer to the container, with optional arguments of the type ("community" [default], "enterprise", or "mageos") and version ([default] is defined in `bin/download`). Ex. `bin/download mageos` or `bin/download enterprise 2.4.7-p3` +- `bin/download`: Download specific Magento version from Composer to the container, with optional arguments of the type ("community" [default], "enterprise", or "mageos") and version ([default] is defined in `bin/download`). Ex. `bin/download mageos` or `bin/download enterprise 2.4.8` - `bin/ece-patches`: Run the Cloud Patches CLI. Ex: `bin/ece-tools apply` - `bin/fixowns`: This will fix filesystem ownerships within the container. - `bin/fixperms`: This will fix filesystem permissions within the container. @@ -359,7 +334,7 @@ It is recommended to keep your root docker config files in one repository, and y - `bin/setup-pwa-studio-sampledata`: This script makes it easier to install Venia sample data. Pass in your base site domain, otherwise the default `master-7rqtwti-mfwmkrjfqvbjk.us-4.magentosite.cloud` will be used. Ex: `bin/setup-pwa-studio-sampledata magento.test`. - `bin/setup-ssl`: Generate an SSL certificate for one or more domains. Ex. `bin/setup-ssl magento.test foo.test` - `bin/setup-ssl-ca`: Generate a certificate authority and copy it to the host. -- `bin/spx`: Disable or enable output compression to enable or disbale SPX. Accepts params `disable` (default) or `enable`. Ex. `bin/spx enable` +- `bin/spx`: Disable or enable output compression to enable or disable SPX. Accepts params `disable` (default) or `enable`. Ex. `bin/spx enable` - `bin/start`: Start all containers, good practice to use this instead of `docker-compose up -d`, as it may contain additional helpers. - `bin/status`: Check the container status. - `bin/stop`: Stop all project containers. @@ -394,6 +369,21 @@ rm -rf yourproject Then, create your new project directory again so you can attempt the install process again. The `bin/removeall` command removes all previous Docker containers & volumes related to the specific project directory you are within. You can then attempt the install process again. +### Accessing the Magento Backend + +After successfully installing the Magento environment, you can access the backend by following these steps: + +1. Open your web browser and go to the following URL: `https://magento.test/admin/`. + +2. Use the following default credentials to log in: +- **Username:** `john.smith` +- **Password:** `password123` + +3. Upon logging in, you might be prompted to configure Two-Factor Authentication (2FA). This emails you a code to log in with (which you can check with Mailcatcher by visiting `http://{yourdomain}:1080`). By default, the email address used for this purpose is: +- **Email:** `john.smith@gmail.com` + +If you are testing in a local development environment and wish to disable 2FA, you can do so by installing [Mark's DisableTwoFactorAuth module](https://github.com/markshust/magento2-module-disabletwofactorauth). + ### Caching For an improved developer experience, caches are automatically refreshed when related files are updated, courtesy of [cache-clean](https://github.com/mage2tv/magento-cache-clean). This means you can keep all of the standard Magento caches enabled, and this script will only clear the specific caches needed, and only when necessary. diff --git a/compose/Makefile b/compose/Makefile index bce726963..3f8d5289e 100644 --- a/compose/Makefile +++ b/compose/Makefile @@ -39,6 +39,7 @@ help: @echo "$(call format,dev-urn-catalog-generate,'Generate URNs for PHPStorm and remap paths to local host.')" @echo "$(call format,devconsole,'Alias for n98-magerun2 dev:console.')" @echo "$(call format,docker-compose,'Support V1 (`docker-compose`) and V2 (`docker compose`) docker compose command, and use custom configuration files.')" + @echo "$(call format,docker-start,'Start the Docker application (either Orbstack or Docker Desktop)" @echo "$(call format,docker-stats,'Display status for CPU$(comma) memory usage$(comma) and memory limit of currently-running Docker containers.')" @echo "$(call format,download,'Download & extract specific Magento version to the src directory.')" @echo "$(call format,ece-patches,'Run the Cloud Patches CLI.')" diff --git a/compose/bin/cron b/compose/bin/cron index 70f5689e2..41c4b1559 100755 --- a/compose/bin/cron +++ b/compose/bin/cron @@ -1,5 +1,16 @@ #!/usr/bin/env bash [ -z "$1" ] && echo "Please specify a service operation (start|stop|status|restart|reload|force-reload)" && exit + +if [ "$1" == "start" ]; then + # Create the .cron-enabled file when starting cron + bin/cli touch /var/www/html/var/.cron-enabled +fi + +if [ "$1" == "stop" ]; then + # Remove the .cron-enabled file when stopping cron + bin/cli rm -f /var/www/html/var/.cron-enabled +fi + bin/root service cron "$@" bin/root touch /var/www/html/var/.setup_cronjob_status /var/www/html/var/.update_cronjob_status bin/root chown app:app /var/www/html/var/.setup_cronjob_status /var/www/html/var/.update_cronjob_status diff --git a/compose/bin/docker-start b/compose/bin/docker-start new file mode 100644 index 000000000..4038ed526 --- /dev/null +++ b/compose/bin/docker-start @@ -0,0 +1,53 @@ +#!/usr/bin/env bash + +# Function to check if Docker daemon is running +docker_running() { + docker stats --no-stream &> /dev/null + return $? +} + +# Check if OrbStack is installed and not running +if [ -d "/Applications/OrbStack.app" ]; then + echo "* OrbStack is installed" + + if (! docker_running); then + echo "* Starting OrbStack..." + open /Applications/OrbStack.app + + # Wait until Docker daemon is running via OrbStack + while (! docker_running); do + echo "* Waiting for OrbStack to initialize Docker..." + sleep 2 + done + + echo "* Docker is now running via OrbStack" + exit 0 + else + echo "* Docker is already running (possibly via OrbStack)" + exit 0 + fi +fi + +# Check if Docker Desktop is installed +if [ -d "/Applications/Docker.app" ]; then + echo "* Docker Desktop is installed" + + # Check if Docker is running + if (! docker_running); then + echo "* Starting Docker Desktop..." + open /Applications/Docker.app + + # Wait until Docker daemon is running + while (! docker_running); do + echo "* Waiting for Docker Desktop to initialize..." + sleep 2 + done + + echo "* Docker Desktop is now running" + else + echo "* Docker is already running" + fi +else + echo "* Docker Desktop is not installed. Please install Docker Desktop or OrbStack." + exit 1 +fi diff --git a/compose/bin/setup-ssl b/compose/bin/setup-ssl index ef27487a2..d928fe9ff 100755 --- a/compose/bin/setup-ssl +++ b/compose/bin/setup-ssl @@ -1,5 +1,5 @@ #!/usr/bin/env bash -[ -z "$1" ] && echo "Please specify a domain (ex. mydomain.test)" && exit +[ $# -eq 0 ] && echo "Please specify at least one domain (ex. mydomain.test)" && exit # Generate certificate authority if not already setup if ! bin/docker-compose exec -T -u root app cat /root/.local/share/mkcert/rootCA.pem | grep -q 'BEGIN CERTIFICATE'; then diff --git a/compose/bin/start b/compose/bin/start index 0c61421cc..7f45172b4 100755 --- a/compose/bin/start +++ b/compose/bin/start @@ -66,4 +66,10 @@ bin/docker-compose up -d --remove-orphans "$@" ## Then uncomment the below line (and leave uncommented) to start the agent automatically with bin/start: #bin/root /etc/init.d/blackfire-agent start +# Check if cron was previously enabled and restart it if needed +if bin/cli test -f /var/www/html/var/.cron-enabled; then + echo "Cron was previously enabled, restarting cron service..." + bin/cron start +fi + bin/cache-clean --watch diff --git a/compose/compose.yaml b/compose/compose.yaml index 91d10bd7a..08fd75db9 100644 --- a/compose/compose.yaml +++ b/compose/compose.yaml @@ -1,7 +1,7 @@ ## Mark Shust's Docker Configuration for Magento ## (https://github.com/markshust/docker-magento) ## -## Version 50.0.0 +## Version 51.0.0 ## To use SSH, see https://github.com/markshust/docker-magento#ssh ## Linux users, see https://github.com/markshust/docker-magento#linux diff --git a/compose/env/elasticsearch.env b/compose/env/elasticsearch.env index 5856225ce..f7c1f2a18 100644 --- a/compose/env/elasticsearch.env +++ b/compose/env/elasticsearch.env @@ -1,2 +1,5 @@ ES_HOST=elasticsearch ES_PORT=9200 + +# Compatibility with ARM64/Apple M-series chips +_JAVA_OPTIONS="-XX:UseSVE=0" diff --git a/compose/env/opensearch.env b/compose/env/opensearch.env index 2a5680329..2ffcc67ee 100644 --- a/compose/env/opensearch.env +++ b/compose/env/opensearch.env @@ -3,3 +3,6 @@ OPENSEARCH_PORT=9200 # Prevent security patch conflicts with core M2 code DISABLE_SECURITY_PLUGIN=true + +# Compatibility with ARM64/Apple M-series chips +_JAVA_OPTIONS="-XX:UseSVE=0" diff --git a/images/nginx/1.24/Dockerfile b/images/nginx/1.24/Dockerfile index 39c2d8d5f..e0ecef590 100644 --- a/images/nginx/1.24/Dockerfile +++ b/images/nginx/1.24/Dockerfile @@ -1,5 +1,5 @@ FROM nginx:1.24-alpine -MAINTAINER Mark Shust +LABEL maintainer="Mark Shust " ARG APP_ID=1000 diff --git a/images/nginx/1.24/conf/nginx.conf b/images/nginx/1.24/conf/nginx.conf index 59e1e89d1..28b07f70a 100644 --- a/images/nginx/1.24/conf/nginx.conf +++ b/images/nginx/1.24/conf/nginx.conf @@ -30,7 +30,7 @@ http { #gzip on; - client_max_body_size 20M; + client_max_body_size 100M; include /etc/nginx/conf.d/*.conf; } diff --git a/images/php/8.1/Dockerfile b/images/php/8.1/Dockerfile index ec5e62cee..7698c1f1c 100644 --- a/images/php/8.1/Dockerfile +++ b/images/php/8.1/Dockerfile @@ -8,7 +8,7 @@ RUN groupadd -g "$APP_ID" app \ RUN mkdir -p /etc/nginx/html /var/www/html /sock \ && chown -R app:app /etc/nginx /var/www /usr/local/etc/php/conf.d /sock -RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash - +RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - RUN apt-get update && apt-get install -y \ cron \ @@ -42,26 +42,14 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* RUN pecl channel-update pecl.php.net && pecl install \ - redis-6.1.0 \ + redis-6.2.0 \ ssh2-1.4.1 \ - swoole-6.0.0 \ - xdebug-3.4.1 \ + swoole-6.0.2 \ + xdebug-3.4.2 \ + imagick-3.8.0RC2 \ && pecl clear-cache \ && rm -rf /tmp/pear -RUN imagick_branch="28f27044e435a2b203e32675e942eb8de620ee58" \ - && curl -L https://github.com/Imagick/imagick/archive/$imagick_branch.zip -o imagick.zip \ - && unzip imagick.zip \ - && rm imagick.zip \ - && cd imagick-$imagick_branch \ - && phpize \ - && ./configure --with-php-config=/usr/local/bin/php-config \ - && make \ - && make install \ - && echo "extension=imagick.so" >> $PHP_INI_DIR/conf.d/imagick.ini \ - && cd .. \ - && rm -rf imagick-$imagick_branch - RUN docker-php-ext-configure \ gd --with-freetype --with-jpeg --with-webp \ && docker-php-ext-install \ @@ -99,7 +87,7 @@ RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \ && mv /tmp/blackfire/blackfire-*.so $(php -r "echo ini_get ('extension_dir');")/blackfire.so \ && rm -rf /tmp/blackfire /tmp/blackfire-probe.tar.gz -RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ +RUN git clone --branch v0.4.18 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ && cd /usr/lib/php-spx \ && phpize \ && ./configure \ @@ -107,7 +95,7 @@ RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php && make install RUN curl -sS https://getcomposer.org/installer | \ - php -- --version=2.2.24 --install-dir=/usr/local/bin --filename=composer + php -- --version=2.7.9 --install-dir=/usr/local/bin --filename=composer COPY conf/blackfire.ini $PHP_INI_DIR/conf.d/blackfire.ini COPY conf/spx.ini $PHP_INI_DIR/conf.d/spx.ini diff --git a/images/php/8.2/Dockerfile b/images/php/8.2/Dockerfile index d3c621659..650b2779d 100644 --- a/images/php/8.2/Dockerfile +++ b/images/php/8.2/Dockerfile @@ -8,7 +8,7 @@ RUN groupadd -g "$APP_ID" app \ RUN mkdir -p /etc/nginx/html /var/www/html /sock \ && chown -R app:app /etc/nginx /var/www /usr/local/etc/php/conf.d /sock -RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - +RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - RUN apt-get update && apt-get install -y \ cron \ @@ -42,26 +42,14 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* RUN pecl channel-update pecl.php.net && pecl install \ - redis-6.1.0 \ + redis-6.2.0 \ ssh2-1.4.1 \ - swoole-6.0.0 \ - xdebug-3.4.1 \ + swoole-6.0.2 \ + xdebug-3.4.2 \ + imagick-3.8.0RC2 \ && pecl clear-cache \ && rm -rf /tmp/pear -RUN imagick_branch="28f27044e435a2b203e32675e942eb8de620ee58" \ - && curl -L https://github.com/Imagick/imagick/archive/$imagick_branch.zip -o imagick.zip \ - && unzip imagick.zip \ - && rm imagick.zip \ - && cd imagick-$imagick_branch \ - && phpize \ - && ./configure --with-php-config=/usr/local/bin/php-config \ - && make \ - && make install \ - && echo "extension=imagick.so" >> $PHP_INI_DIR/conf.d/imagick.ini \ - && cd .. \ - && rm -rf imagick-$imagick_branch - RUN docker-php-ext-configure \ gd --with-freetype --with-jpeg --with-webp \ && docker-php-ext-install \ @@ -100,7 +88,7 @@ RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \ && mv /tmp/blackfire/blackfire-*.so $(php -r "echo ini_get ('extension_dir');")/blackfire.so \ && rm -rf /tmp/blackfire /tmp/blackfire-probe.tar.gz -RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ +RUN git clone --branch v0.4.18 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ && cd /usr/lib/php-spx \ && phpize \ && ./configure \ @@ -108,7 +96,7 @@ RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php && make install RUN curl -sS https://getcomposer.org/installer | \ - php -- --version=2.7.9 --install-dir=/usr/local/bin --filename=composer + php -- --version=2.8.6 --install-dir=/usr/local/bin --filename=composer COPY conf/blackfire.ini $PHP_INI_DIR/conf.d/blackfire.ini COPY conf/spx.ini $PHP_INI_DIR/conf.d/spx.ini diff --git a/images/php/8.3/Dockerfile b/images/php/8.3/Dockerfile index a0df8c85e..e3bcee253 100644 --- a/images/php/8.3/Dockerfile +++ b/images/php/8.3/Dockerfile @@ -8,7 +8,7 @@ RUN groupadd -g "$APP_ID" app \ RUN mkdir -p /etc/nginx/html /var/www/html /sock \ && chown -R app:app /etc/nginx /var/www /usr/local/etc/php/conf.d /sock -RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - +RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - RUN apt-get update && apt-get install -y \ cron \ @@ -42,26 +42,14 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* RUN pecl channel-update pecl.php.net && pecl install \ - redis-6.1.0 \ + redis-6.2.0 \ ssh2-1.4.1 \ - swoole-6.0.0 \ - xdebug-3.4.1 \ + swoole-6.0.2 \ + xdebug-3.4.2 \ + imagick-3.8.0RC2 \ && pecl clear-cache \ && rm -rf /tmp/pear -RUN imagick_branch="28f27044e435a2b203e32675e942eb8de620ee58" \ - && curl -L https://github.com/Imagick/imagick/archive/$imagick_branch.zip -o imagick.zip \ - && unzip imagick.zip \ - && rm imagick.zip \ - && cd imagick-$imagick_branch \ - && phpize \ - && ./configure --with-php-config=/usr/local/bin/php-config \ - && make \ - && make install \ - && echo "extension=imagick.so" >> $PHP_INI_DIR/conf.d/imagick.ini \ - && cd .. \ - && rm -rf imagick-$imagick_branch - RUN docker-php-ext-configure \ gd --with-freetype --with-jpeg --with-webp \ && docker-php-ext-install \ @@ -100,7 +88,7 @@ RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \ && mv /tmp/blackfire/blackfire-*.so $(php -r "echo ini_get ('extension_dir');")/blackfire.so \ && rm -rf /tmp/blackfire /tmp/blackfire-probe.tar.gz -RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ +RUN git clone --branch v0.4.18 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ && cd /usr/lib/php-spx \ && phpize \ && ./configure \ @@ -108,7 +96,7 @@ RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php && make install RUN curl -sS https://getcomposer.org/installer | \ - php -- --version=2.7.9 --install-dir=/usr/local/bin --filename=composer + php -- --version=2.8.6 --install-dir=/usr/local/bin --filename=composer COPY conf/blackfire.ini $PHP_INI_DIR/conf.d/blackfire.ini COPY conf/spx.ini $PHP_INI_DIR/conf.d/spx.ini diff --git a/images/php/8.4/Dockerfile b/images/php/8.4/Dockerfile index d56c7999e..d462e34bd 100644 --- a/images/php/8.4/Dockerfile +++ b/images/php/8.4/Dockerfile @@ -8,7 +8,7 @@ RUN groupadd -g "$APP_ID" app \ RUN mkdir -p /etc/nginx/html /var/www/html /sock \ && chown -R app:app /etc/nginx /var/www /usr/local/etc/php/conf.d /sock -RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - +RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - RUN apt-get update && apt-get install -y \ cron \ @@ -42,26 +42,14 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* RUN pecl channel-update pecl.php.net && pecl install \ - redis-6.1.0 \ + redis-6.2.0 \ ssh2-1.4.1 \ - swoole-6.0.0 \ - xdebug-3.4.1 \ + swoole-6.0.2 \ + xdebug-3.4.2 \ + imagick-3.8.0RC2 \ && pecl clear-cache \ && rm -rf /tmp/pear -RUN imagick_branch="28f27044e435a2b203e32675e942eb8de620ee58" \ - && curl -L https://github.com/Imagick/imagick/archive/$imagick_branch.zip -o imagick.zip \ - && unzip imagick.zip \ - && rm imagick.zip \ - && cd imagick-$imagick_branch \ - && phpize \ - && ./configure --with-php-config=/usr/local/bin/php-config \ - && make \ - && make install \ - && echo "extension=imagick.so" >> $PHP_INI_DIR/conf.d/imagick.ini \ - && cd .. \ - && rm -rf imagick-$imagick_branch - RUN docker-php-ext-configure \ gd --with-freetype --with-jpeg --with-webp \ && docker-php-ext-install \ @@ -92,9 +80,7 @@ RUN docker-php-ext-configure \ ssh2 \ xdebug -# Temporary workaround for PHP 8.4 RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \ - && version=83 \ && architecture=$(uname -m) \ && curl -A "Docker" -o /tmp/blackfire-probe.tar.gz -D - -L -s https://blackfire.io/api/v1/releases/probe/php/linux/$architecture/$version \ && mkdir -p /tmp/blackfire \ @@ -102,7 +88,7 @@ RUN version=$(php -r "echo PHP_MAJOR_VERSION.PHP_MINOR_VERSION;") \ && mv /tmp/blackfire/blackfire-*.so $(php -r "echo ini_get ('extension_dir');")/blackfire.so \ && rm -rf /tmp/blackfire /tmp/blackfire-probe.tar.gz -RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ +RUN git clone --branch v0.4.18 --depth=1 https://github.com/NoiseByNorthwest/php-spx.git /usr/lib/php-spx \ && cd /usr/lib/php-spx \ && phpize \ && ./configure \ @@ -110,7 +96,7 @@ RUN git clone --branch v0.4.17 --depth=1 https://github.com/NoiseByNorthwest/php && make install RUN curl -sS https://getcomposer.org/installer | \ - php -- --version=2.7.9 --install-dir=/usr/local/bin --filename=composer + php -- --version=2.8.6 --install-dir=/usr/local/bin --filename=composer COPY conf/blackfire.ini $PHP_INI_DIR/conf.d/blackfire.ini COPY conf/spx.ini $PHP_INI_DIR/conf.d/spx.ini