Skip to content

Commit

Permalink
Merge pull request #77 from sparkfabrik/feat/fastcgi_user_agent
Browse files Browse the repository at this point in the history
feat: log user agent, restore old and used PHP versions and actions version upgrade
  • Loading branch information
Monska85 authored May 22, 2024
2 parents da17564 + 6c02772 commit 637ae0b
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 19 deletions.
30 changes: 17 additions & 13 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
name: Docker

on:
push:
branches:
- "master"
pull_request:
branches:
- "master"
push:
branches: "master"

env:
IMAGE_NAME: docker-php-base-image
Expand All @@ -16,16 +14,16 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
tag: [8-3-2, 8-2-3, 8-1-16]
tag: [8-3-2, 8-2-3, 8-1-16, 8-1-10]
flavour: ["", "-rootless"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- 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: Build and test the image
run: make build-${{ matrix.tag }}${{ matrix.flavour }}
Expand All @@ -36,10 +34,16 @@ jobs:
if: github.ref == 'refs/heads/master'
strategy:
matrix:
tag: [8.3.2-fpm-alpine3.18, 8.2.3-fpm-alpine3.16, 8.1.16-fpm-alpine3.16]
tag:
[
8.3.2-fpm-alpine3.18,
8.2.3-fpm-alpine3.16,
8.1.16-fpm-alpine3.16,
8.1.10-fpm-alpine3.16,
]
flavour: ["", "-rootless"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

# Refs https://github.com/docker/login-action#github-container-registry
- name: Login to GitHub Container Registry
Expand All @@ -61,10 +65,10 @@ jobs:
test -d $BASE_FOLDER && test -f $BASE_FOLDER/Dockerfile
- 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: Build and push images to GitHub Container Registry
if: ${{ matrix.flavour == '' }}
Expand Down
2 changes: 1 addition & 1 deletion 8/fpm-conf-templates/zz3-structured-logs.conf
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[www]
access.format = '{"requestId": "%{WEBSERVER_REQUEST_ID}e", "status": %s, "time": "%t", "requestMethod": "%m", "requestUrl": "%r%Q%q", "requestUri": "%{REQUEST_URI}e", "remoteAddr": "%{REMOTE_ADDR}e", "http_x_forwarded_for": "%{X_FORWARDED_FOR}e", "proxy_add_x_forwarded_for": "%{ADD_X_FORWARDED_FOR}e"}';
access.format = '{"requestId": "%{WEBSERVER_REQUEST_ID}e", "status": %s, "time": "%t", "requestMethod": "%m", "requestUrl": "%r%Q%q", "requestUri": "%{REQUEST_URI}e", "remoteAddr": "%{REMOTE_ADDR}e", "http_x_forwarded_for": "%{X_FORWARDED_FOR}e", "proxy_add_x_forwarded_for": "%{ADD_X_FORWARDED_FOR}e", "http_user_agent": "%{HTTP_USER_AGENT}e"}';
9 changes: 4 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,11 @@ COMPOSER_VERSION ?= 2.5.4
# build-8-1-12-rootless: PHPVER=8.1.12-fpm-alpine3.16
# build-8-1-12-rootless: build-rootless-template

# build-8-1-10: PHPVER=8.1.10-fpm-alpine3.16
# build-8-1-10: build-template
build-8-1-10: PHPVER=8.1.10-fpm-alpine3.16
build-8-1-10: build-template

# build-8-1-10-rootless: PHPVER=8.1.10-fpm-alpine3.16
# build-8-1-10-rootless: build-rootless-template
build-8-1-10-rootless: PHPVER=8.1.10-fpm-alpine3.16
build-8-1-10-rootless: build-rootless-template

build-8-1-16: PHPVER=8.1.16-fpm-alpine3.16
build-8-1-16: build-template
Expand All @@ -158,7 +158,6 @@ build-8-3-2: build-template
build-8-3-2-rootless: PHPVER=8.3.2-fpm-alpine3.18
build-8-3-2-rootless: build-rootless-template


build-template: guessing-folder build-test-image
docker buildx build \
--load \
Expand Down

0 comments on commit 637ae0b

Please sign in to comment.