Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v7.0.0 #185

Merged
merged 19 commits into from
Nov 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Always use LF endings.
* text eol=lf
2 changes: 1 addition & 1 deletion .github/workflows/auto-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
steps:
-
name: Checkout Branch ${{ github.ref_name }}
uses: actions/checkout@v3
uses: actions/checkout@v4
-
name: Create Pull Request
uses: bfren/pull-request@v2
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
steps:
-
name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
build:
strategy:
fail-fast: false
Expand All @@ -22,7 +22,7 @@ jobs:
steps:
-
name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
-
name: Get repository name
run: echo "REPOSITORY_NAME=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')" >> $GITHUB_ENV
Expand All @@ -35,20 +35,20 @@ jobs:
id: version
-
name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
context: .
file: ./${{ matrix.php }}/Dockerfile
Expand All @@ -59,7 +59,7 @@ jobs:
platforms: linux/amd64,linux/arm/v7,linux/arm64
tags: |
bfren/nginx-php:php${{ matrix.php }}-dev
bfren/nginx-php:php${{ matrix.php }}-${{ steps.version.outputs.contents }}-beta
bfren/nginx-php:php${{ matrix.php }}-${{ steps.version.outputs.contents }}-dev
-
name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
10 changes: 5 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
-
name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
-
name: Get repository name
run: echo "REPOSITORY_NAME=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')" >> $GITHUB_ENV
Expand Down Expand Up @@ -46,20 +46,20 @@ jobs:
id: version
-
name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
-
name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push
id: docker_build
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
context: .
file: ./${{ matrix.php }}/Dockerfile
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/update-readme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ jobs:
shell: bash
-
name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4
-
name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
Expand Down
57 changes: 30 additions & 27 deletions 7.4/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,38 +1,41 @@
FROM bfren/nginx:nginx1.20-alpine3.15-5.0.16
#======================================================================================================================
# STAGE 0: get Nu scripts from the PHP image overlay
#======================================================================================================================

FROM alpine AS php

WORKDIR /tmp
RUN \
# get the Nu scripts from the PHP image overlay
echo "Cloning Alpine overlay." && \
apk add git && git clone --branch v2.0.0 https://github.com/bfren/docker-php.git && \
mkdir /overlay && \
mv docker-php/overlay/etc /overlay/


#======================================================================================================================
# STAGE 1: create final image
#======================================================================================================================

FROM bfren/nginx:nginx1.20-alpine3.15-6.0.0 as final
COPY --from=php /overlay /

LABEL org.opencontainers.image.source="https://github.com/bfren/docker-nginx-php"

ARG BF_IMAGE
ARG BF_VERSION

COPY ./overlay /
COPY ./7.4/overlay /

ENV \
# PHP config directory
PHP_DIR="/etc/php7" \
# www.conf override: log_level
PHP_FPM_LOG_LEVEL="notice" \
# php.ini template to use, or 'custom' if you want to bind your own custom php.ini -
# which will cause the other PHP_INI_* environment variables to be ignored
PHP_INI="production" \
# php.ini override: display_errors
PHP_INI_DISPLAY_ERRORS= \
# php.ini override: display_startup_errors
PHP_INI_DISPLAY_STARTUP_ERRORS= \
# php.ini override: error_log
PHP_INI_ERROR_LOG="/var/log/php7/error.log" \
# php.ini override: err-r_reporting
PHP_INI_ERROR_REPORTING= \
# php.ini override: memory_limit
PHP_INI_MEMORY_LIMIT="256M" \
# php.ini override: max_post
PHP_INI_MAX_POST="64M" \
# php.ini override: max_upload
PHP_INI_MAX_UPLOAD="64M" \
# php.ini override: session_max_lifetime
PHP_SESSION_MAX_LIFETIME=86400 \
BF_PHP_DIR="/etc/php7" \
# offical php.ini template to download
BF_PHP_ENV="production" \
# space-separated extensions to install on startup
PHP_EXT=

COPY ./overlay /
COPY ./7.4/overlay /
BF_PHP_EXT= \
# PHP package prefix
BF_PHP_PREFIX="php7"

RUN bf-install
1 change: 1 addition & 0 deletions 7.4/PHP_PREFIX
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
php7
11 changes: 0 additions & 11 deletions 7.4/overlay/etc/bf/init.d/24-php-ext

This file was deleted.

22 changes: 0 additions & 22 deletions 7.4/overlay/tmp/install-php

This file was deleted.

57 changes: 30 additions & 27 deletions 8.0/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,38 +1,41 @@
FROM bfren/nginx:nginx1.22-alpine3.16-5.0.16
#======================================================================================================================
# STAGE 0: get Nu scripts from the PHP image overlay
#======================================================================================================================

FROM alpine AS php

WORKDIR /tmp
RUN \
# get the Nu scripts from the PHP image overlay
echo "Cloning Alpine overlay." && \
apk add git && git clone --branch v2.0.0 https://github.com/bfren/docker-php.git && \
mkdir /overlay && \
mv docker-php/overlay/etc /overlay/


#======================================================================================================================
# STAGE 1: create final image
#======================================================================================================================

FROM bfren/nginx:nginx1.22-alpine3.16-6.0.0 as final
COPY --from=php /overlay /

LABEL org.opencontainers.image.source="https://github.com/bfren/docker-nginx-php"

ARG BF_IMAGE
ARG BF_VERSION

COPY ./overlay /
COPY ./8.0/overlay /

ENV \
# PHP config directory
PHP_DIR="/etc/php8" \
# www.conf override: log_level
PHP_FPM_LOG_LEVEL="notice" \
# php.ini template to use, or 'custom' if you want to bind your own custom php.ini -
# which will cause the other PHP_INI_* environment variables to be ignored
PHP_INI="production" \
# php.ini override: display_errors
PHP_INI_DISPLAY_ERRORS= \
# php.ini override: display_startup_errors
PHP_INI_DISPLAY_STARTUP_ERRORS= \
# php.ini override: error_log
PHP_INI_ERROR_LOG="/var/log/php8/error.log" \
# php.ini override: err-r_reporting
PHP_INI_ERROR_REPORTING= \
# php.ini override: memory_limit
PHP_INI_MEMORY_LIMIT="256M" \
# php.ini override: max_post
PHP_INI_MAX_POST="64M" \
# php.ini override: max_upload
PHP_INI_MAX_UPLOAD="64M" \
# php.ini override: session_max_lifetime
PHP_SESSION_MAX_LIFETIME=86400 \
BF_PHP_DIR="/etc/php8" \
# offical php.ini template to download
BF_PHP_ENV="production" \
# space-separated extensions to install on startup
PHP_EXT=

COPY ./overlay /
COPY ./8.0/overlay /
BF_PHP_EXT= \
# PHP package prefix
BF_PHP_PREFIX="php8"

RUN bf-install
1 change: 1 addition & 0 deletions 8.0/PHP_PREFIX
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
php8
11 changes: 0 additions & 11 deletions 8.0/overlay/etc/bf/init.d/24-php-ext

This file was deleted.

22 changes: 0 additions & 22 deletions 8.0/overlay/tmp/install-php

This file was deleted.

57 changes: 30 additions & 27 deletions 8.1/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,38 +1,41 @@
FROM bfren/nginx:nginx1.24-alpine3.18-5.0.16
#======================================================================================================================
# STAGE 0: get Nu scripts from the PHP image overlay
#======================================================================================================================

FROM alpine AS php

WORKDIR /tmp
RUN \
# get the Nu scripts from the PHP image overlay
echo "Cloning Alpine overlay." && \
apk add git && git clone --branch v2.0.0 https://github.com/bfren/docker-php.git && \
mkdir /overlay && \
mv docker-php/overlay/etc /overlay/


#======================================================================================================================
# STAGE 1: create final image
#======================================================================================================================

FROM bfren/nginx:nginx1.24-alpine3.18-6.0.0 as final
COPY --from=php /overlay /

LABEL org.opencontainers.image.source="https://github.com/bfren/docker-nginx-php"

ARG BF_IMAGE
ARG BF_VERSION

COPY ./overlay /
COPY ./8.1/overlay /

ENV \
# PHP config directory
PHP_DIR="/etc/php81" \
# www.conf override: log_level
PHP_FPM_LOG_LEVEL="notice" \
# php.ini template to use, or 'custom' if you want to bind your own custom php.ini -
# which will cause the other PHP_INI_* environment variables to be ignored
PHP_INI="production" \
# php.ini override: display_errors
PHP_INI_DISPLAY_ERRORS= \
# php.ini override: display_startup_errors
PHP_INI_DISPLAY_STARTUP_ERRORS= \
# php.ini override: error_log
PHP_INI_ERROR_LOG="/var/log/php81/error.log" \
# php.ini override: err-r_reporting
PHP_INI_ERROR_REPORTING= \
# php.ini override: memory_limit
PHP_INI_MEMORY_LIMIT="256M" \
# php.ini override: max_post
PHP_INI_MAX_POST="64M" \
# php.ini override: max_upload
PHP_INI_MAX_UPLOAD="64M" \
# php.ini override: session_max_lifetime
PHP_SESSION_MAX_LIFETIME=86400 \
BF_PHP_DIR="/etc/php81" \
# offical php.ini template to download
BF_PHP_ENV="production" \
# space-separated extensions to install on startup
PHP_EXT=

COPY ./overlay /
COPY ./8.1/overlay /
BF_PHP_EXT= \
# PHP package prefix
BF_PHP_PREFIX="php81"

RUN bf-install
1 change: 1 addition & 0 deletions 8.1/PHP_PREFIX
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
php81
Loading