Skip to content

Commit

Permalink
Merge pull request #394 from mistraloz/feature/add-8.4-remove-7.2-and…
Browse files Browse the repository at this point in the history
…-7.3

Add php8.4
  • Loading branch information
mistraloz authored Dec 5, 2024
2 parents 87616d3 + c1c00dc commit 57cb6d7
Show file tree
Hide file tree
Showing 119 changed files with 1,017 additions and 1,553 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php_version: ['8.3','8.2','8.1','8.0','7.4','7.3','7.2']
php_version: ['8.4', '8.3','8.2','8.1','8.0','7.4']
variant: ['apache','cli','fpm']
# builder: [ {arch: "amd64", os: "ubuntu-latest"}, {arch: "arm64", os: "macos-latest"}]
builder: [ {arch: "amd64", os: "ubuntu-latest"}, {arch: "arm64", os: "ubuntu-latest"}]
Expand Down Expand Up @@ -64,7 +64,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php_version: ['8.3','8.2','8.1','8.0','7.4','7.3','7.2']
php_version: ['8.4', 8.3','8.2','8.1','8.0','7.4']
variant: ['apache','cli','fpm']
steps:
- name: Checkout
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,4 +69,4 @@ The sqlite3 extension was previously enabled by default, but must now be enabled

The project layout has been deeply changed. There is now only one branch for all the PHP versions.
Each extension now has its own installation script in the `/extensions/core` directory with symlinks for the
extensions in the `/extensions/7.1` and `/extensions/7.2` directory based on the targeted PHP version.
extensions in the `/extensions/8.3` and `/extensions/8.4` directory based on the targeted PHP version.
2 changes: 1 addition & 1 deletion Dockerfile.apache
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ARG REPO="thecodingmachine/php"
ARG TAG_PREFIX=""

ARG FROM_IMAGE="${REPO}:${TAG_PREFIX}${PHP_VERSION}-${GLOBAL_VERSION}-slim-apache"
FROM $FROM_IMAGE
FROM ${FROM_IMAGE}
LABEL authors="Julien Neuhart <[email protected]>, David Négrier <[email protected]>"
SHELL ["/bin/bash", "-o", "pipefail", "-c"]

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.cli
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ARG REPO="thecodingmachine/php"
ARG TAG_PREFIX=""

ARG FROM_IMAGE="${REPO}:${TAG_PREFIX}${PHP_VERSION}-${GLOBAL_VERSION}-slim-cli"
FROM $FROM_IMAGE
FROM ${FROM_IMAGE}
LABEL authors="Julien Neuhart <[email protected]>, David Négrier <[email protected]>"
SHELL ["/bin/bash", "-o", "pipefail", "-c"]

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.fpm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ARG REPO="thecodingmachine/php"
ARG TAG_PREFIX=""

ARG FROM_IMAGE="${REPO}:${TAG_PREFIX}${PHP_VERSION}-${GLOBAL_VERSION}-slim-fpm"
FROM $FROM_IMAGE
FROM ${FROM_IMAGE}
LABEL authors="Julien Neuhart <[email protected]>, David Négrier <[email protected]>"
SHELL ["/bin/bash", "-o", "pipefail", "-c"]

Expand Down
8 changes: 4 additions & 4 deletions Dockerfile.slim.apache
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ RUN composer global require bamarni/symfony-console-autocomplete && \
USER root


ENV APACHE_CONFDIR /etc/apache2
ENV APACHE_ENVVARS $APACHE_CONFDIR/envvars
ENV APACHE_CONFDIR=/etc/apache2
ENV APACHE_ENVVARS=$APACHE_CONFDIR/envvars

RUN set -eux; \
apt-get update; \
Expand Down Expand Up @@ -199,8 +199,8 @@ COPY utils/apache-docker-php.conf /etc/apache2/conf-available/docker-php.conf

RUN a2enconf docker-php

ENV PHP_EXTRA_BUILD_DEPS apache2-dev
ENV PHP_EXTRA_CONFIGURE_ARGS --with-apxs2 --disable-cgi
ENV PHP_EXTRA_BUILD_DEPS=apache2-dev
ENV PHP_EXTRA_CONFIGURE_ARGS="--with-apxs2 --disable-cgi"

# https://httpd.apache.org/docs/2.4/stopping.html#gracefulstop
STOPSIGNAL SIGWINCH
Expand Down
6 changes: 1 addition & 5 deletions Dockerfile.slim.fpm
Original file line number Diff line number Diff line change
Expand Up @@ -265,11 +265,7 @@ RUN ln -s /etc/php/${PHP_VERSION}/mods-available/generated_conf.ini /etc/php/${P
sed -i 's/^user = www-data/;user = www-data/g' /etc/php/${PHP_VERSION}/fpm/pool.d/www.conf && \
sed -i 's/^group = www-data/;group = www-data/g' /etc/php/${PHP_VERSION}/fpm/pool.d/www.conf && \
sed -i 's#listen = /run/php/php${PHP_VERSION}-fpm.sock#;listen = /run/php/php${PHP_VERSION}-fpm.sock#g' /etc/php/${PHP_VERSION}/fpm/pool.d/www.conf && \
sed -i "s#pid = /run/php/php${PHP_VERSION}-fpm.pid#;pid = /run/php/php${PHP_VERSION}-fpm.pid#g" /etc/php/${PHP_VERSION}/fpm/php-fpm.conf && \
if [[ "$PHP_VERSION" = "7.2" ]]; then \
sed -i 's/^log_limit =/;log_limit =/g' /etc/php/${PHP_VERSION}/fpm/pool.d/docker.conf && \
sed -i 's/^decorate_workers_output =/;decorate_workers_output =/g' /etc/php/${PHP_VERSION}/fpm/pool.d/docker.conf; \
fi
sed -i "s#pid = /run/php/php${PHP_VERSION}-fpm.pid#;pid = /run/php/php${PHP_VERSION}-fpm.pid#g" /etc/php/${PHP_VERSION}/fpm/php-fpm.conf


USER docker
Expand Down
29 changes: 14 additions & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,15 @@ blueprint: ## Generate all blueprints file
@if ! type orbit >/dev/null 2>&1; then echo "Missing orbit dependency, please install from https://github.com/gulien/orbit/"; exit 1; fi
orbit run generate

test-latest: test-8.3 ## Test the latest build only
test-latest: test-8.4 ## Test the latest build only

_test-prerequisites: blueprint
docker pull ubuntu:20.04

test-quick: ## Test 8.0, 8.1, 8.2 and 8.3 quickly
VERSION=8.0 VARIANT=cli $(MAKE) _test-version-quick
VERSION=8.1 VARIANT=cli $(MAKE) _test-version-quick
test-quick: ## Test 8.2, 8.3 and 8.4 quickly
VERSION=8.2 VARIANT=cli $(MAKE) _test-version-quick
VERSION=8.3 VARIANT=cli $(MAKE) _test-version-quick
VERSION=8.4 VARIANT=cli $(MAKE) _test-version-quick

test-8.3: ## Test php8.3 build only
VERSION=8.3 VARIANT=cli $(MAKE) _test-version
Expand All @@ -30,18 +29,18 @@ test-8.1: ## Test php8.1 build only
VERSION=8.1 VARIANT=apache $(MAKE) _test-version
VERSION=8.1 VARIANT=fpm $(MAKE) _test-version

test-8.0: ## Test php8.0 build only
VERSION=8.0 VARIANT=cli $(MAKE) _test-version
VERSION=8.0 VARIANT=apache $(MAKE) _test-version
VERSION=8.0 VARIANT=fpm $(MAKE) _test-version
test-8.4: ## Test php8.4 build only
VERSION=8.4 VARIANT=cli $(MAKE) _test-version
VERSION=8.4 VARIANT=apache $(MAKE) _test-version
VERSION=8.4 VARIANT=fpm $(MAKE) _test-version

test-node: ## Test node builds only
VERSION=8.3 VARIANT=cli NODE=12 $(MAKE) _test-node
VERSION=8.3 VARIANT=cli NODE=14 $(MAKE) _test-node
VERSION=8.3 VARIANT=cli NODE=16 $(MAKE) _test-node
VERSION=8.3 VARIANT=cli NODE=18 $(MAKE) _test-node
VERSION=8.3 VARIANT=cli NODE=20 $(MAKE) _test-node
VERSION=8.3 VARIANT=cli NODE=22 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=12 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=14 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=16 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=18 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=20 $(MAKE) _test-node
VERSION=8.4 VARIANT=cli NODE=22 $(MAKE) _test-node

_test-node: _test-prerequisites ## Test node for VERSION="" and VARIANT=""
docker buildx bake --load \
Expand All @@ -65,4 +64,4 @@ _test-version-quick: _test-prerequisites ## Test php build for VERSION="" and VA
notify-send -u critical "Tests passed with success ($(VERSION)-$(VARIANT)) - without node-*"

clean: ## Clean dangles image after build
rm -rf /tmp/buildx-cache
rm -rf /tmp/buildx-cache
Loading

0 comments on commit 57cb6d7

Please sign in to comment.