Skip to content

Commit d06baf2

Browse files
authored
Merge branch 'release/webserver-improvements-and-fixes' into fix/root-mode-fpm-nginx-startup-race
2 parents c7befe0 + 33352f9 commit d06baf2

96 files changed

Lines changed: 2708 additions & 471 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.dockerignore‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
**/.DS_Store
1+
**/.DS_Store
2+
depot.json

‎.github/ISSUE_TEMPLATE/bug.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ body:
2929
- type: textarea
3030
attributes:
3131
label: Affected Docker Images
32-
description: "Which images does this issue happen in? (for example: `serversideup/php:8.1-cli`, `serversideup/php:8.1-fpm`, etc). You can also run Run `docker inspect --format='{{json .Config.Labels}}' <<image>>` to get additional information."
32+
description: "Which images does this issue happen in? (for example: `serversideup/php:8.4-cli`, `serversideup/php:8.4-fpm`, etc). You can also run Run `docker inspect --format='{{json .Config.Labels}}' <<image>>` to get additional information."
3333
validations:
3434
required: true
3535
- type: textarea

‎.github/actionlint.yaml‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Runner labels that are not GitHub-hosted, so actionlint recognizes them.
2+
# https://depot.dev/docs/github-actions/runner-types
3+
self-hosted-runner:
4+
labels:
5+
- depot-ubuntu-24.04
6+
- depot-ubuntu-24.04-4
7+
- depot-ubuntu-24.04-8
8+
- depot-ubuntu-24.04-16
9+
- depot-ubuntu-24.04-arm
10+
- depot-ubuntu-24.04-arm-4
11+
- depot-ubuntu-24.04-arm-8

‎.github/dependabot.yml‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,11 @@ updates:
66
interval: "daily"
77
allow:
88
- dependency-name: "@serversideup/project-switcher-bar"
9+
- package-ecosystem: "github-actions"
10+
directory: "/"
11+
schedule:
12+
interval: "monthly"
13+
groups:
14+
github-actions:
15+
patterns:
16+
- "*"
Lines changed: 88 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
name: Docker Publish (Beta Images)
2+
run-name: >-
3+
Beta images (${{
4+
github.event.release.tag_name ||
5+
(github.event_name == 'schedule' && 'weekly rebuild') ||
6+
'manual rebuild'
7+
}})
28
39
on:
410
workflow_dispatch:
@@ -7,24 +13,95 @@ on:
713
schedule:
814
- cron: '25 8 * * 1'
915

16+
# A release event and the weekly rebuild must not publish the same tags at the same time.
17+
concurrency:
18+
group: beta-images
19+
20+
permissions: {}
21+
1022
jobs:
11-
get-latest-beta-release:
23+
release:
24+
name: resolve beta release
1225
runs-on: ubuntu-24.04
26+
timeout-minutes: 5
27+
permissions:
28+
contents: read
1329
outputs:
14-
release_tag: ${{ steps.get_latest_beta.outputs.release_tag }}
30+
tag: ${{ steps.release.outputs.tag }}
1531
steps:
16-
- name: Get Latest Beta Release
17-
id: get_latest_beta
32+
# A prerelease event builds the prerelease that fired it. Scheduled and manual runs rebuild the latest prerelease.
33+
- name: Find the beta release to build
34+
id: release
35+
env:
36+
GH_TOKEN: ${{ github.token }}
37+
GH_REPO: ${{ github.repository }}
38+
RELEASE_TAG: ${{ github.event.release.tag_name }}
1839
run: |
19-
LATEST_BETA=$(curl -s https://api.github.com/repos/${{ github.repository }}/releases | jq -r '[.[] | select(.prerelease == true)][0].tag_name')
20-
echo "release_tag=${LATEST_BETA}" >> $GITHUB_OUTPUT
40+
TAG="${RELEASE_TAG:-$(gh api "repos/${GH_REPO}/releases?per_page=30" --jq '[.[] | select(.prerelease)][0].tag_name')}"
41+
if [ -z "$TAG" ] || [ "$TAG" = "null" ]; then
42+
echo "::error title=No beta release found::Could not find a prerelease to build."
43+
exit 1
44+
fi
45+
echo "Building beta release $TAG"
46+
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
2147
22-
build-beta-images:
23-
needs: get-latest-beta-release
24-
uses: ./.github/workflows/service_docker-build-and-publish.yml
48+
setup:
49+
needs: release
50+
uses: ./.github/workflows/service_setup-matrix.yml
51+
permissions:
52+
contents: read
2553
with:
54+
ref: ${{ needs.release.outputs.tag }}
55+
56+
build:
57+
needs: [release, setup]
58+
name: build ${{ matrix.variation }}
59+
strategy:
60+
fail-fast: false
61+
matrix:
62+
variation: ${{ fromJson(needs.setup.outputs.variations) }}
63+
permissions:
64+
contents: read
65+
id-token: write
66+
uses: ./.github/workflows/service_build-images.yml
67+
with:
68+
variation: ${{ matrix.variation }}
69+
matrix: ${{ needs.setup.outputs.matrix }}
70+
ref: ${{ needs.release.outputs.tag }}
2671
registry-repositories: "docker.io/serversideup/php,ghcr.io/serversideup/php"
2772
tag-prefix: "beta"
2873
release-type: "testing"
29-
ref: ${{ needs.get-latest-beta-release.outputs.release_tag }}
30-
secrets: inherit
74+
secrets: inherit
75+
76+
test:
77+
needs: [release, setup, build]
78+
if: always() && needs.setup.result == 'success'
79+
uses: ./.github/workflows/service_test-images.yml
80+
permissions:
81+
contents: read
82+
id-token: write
83+
with:
84+
ref: ${{ needs.release.outputs.tag }}
85+
86+
# Only images that passed the image tests reach a public registry.
87+
publish:
88+
needs: [release, build, test]
89+
if: needs.build.result == 'success' && needs.test.result == 'success'
90+
uses: ./.github/workflows/service_publish-images.yml
91+
permissions:
92+
contents: read
93+
packages: write
94+
id-token: write
95+
with:
96+
ref: ${{ needs.release.outputs.tag }}
97+
secrets: inherit
98+
99+
report:
100+
needs: [release, setup, build, test, publish]
101+
if: always() && needs.setup.result == 'success'
102+
uses: ./.github/workflows/service_report.yml
103+
permissions:
104+
contents: read
105+
with:
106+
matrix: ${{ needs.setup.outputs.matrix }}
107+
ref: ${{ needs.release.outputs.tag }}

‎.github/workflows/action_publish-images-dev-main.yml‎

Lines changed: 0 additions & 14 deletions
This file was deleted.
Lines changed: 87 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
name: Docker Publish (Production Images)
2+
run-name: >-
3+
Production images (${{
4+
github.event.release.tag_name ||
5+
(github.event_name == 'schedule' && 'weekly rebuild') ||
6+
'manual rebuild'
7+
}})
28
39
on:
410
workflow_dispatch:
@@ -7,24 +13,95 @@ on:
713
schedule:
814
- cron: '0 8 * * 2'
915

16+
# A release event and the weekly rebuild must not publish the same tags at the same time.
17+
concurrency:
18+
group: production-images
19+
20+
permissions: {}
21+
1022
jobs:
11-
get-latest-release:
23+
release:
24+
name: resolve release
1225
runs-on: ubuntu-24.04
26+
timeout-minutes: 5
27+
permissions:
28+
contents: read
1329
outputs:
14-
release_tag: ${{ steps.get_latest_release.outputs.release_tag }}
30+
tag: ${{ steps.release.outputs.tag }}
1531
steps:
16-
- name: Get Latest Release
17-
id: get_latest_release
32+
# A release event builds the release that fired it. Scheduled and manual runs rebuild the latest release.
33+
- name: Find the release to build
34+
id: release
35+
env:
36+
GH_TOKEN: ${{ github.token }}
37+
GH_REPO: ${{ github.repository }}
38+
RELEASE_TAG: ${{ github.event.release.tag_name }}
1839
run: |
19-
LATEST_TAG=$(curl -s https://api.github.com/repos/${{ github.repository }}/releases/latest | jq -r .tag_name)
20-
echo "release_tag=${LATEST_TAG}" >> $GITHUB_OUTPUT
40+
TAG="${RELEASE_TAG:-$(gh release view --json tagName --jq .tagName)}"
41+
if [ -z "$TAG" ] || [ "$TAG" = "null" ]; then
42+
echo "::error title=No release found::Could not find a published release to build."
43+
exit 1
44+
fi
45+
echo "Building release $TAG"
46+
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
2147
22-
build-production-images:
23-
needs: get-latest-release
24-
uses: ./.github/workflows/service_docker-build-and-publish.yml
48+
setup:
49+
needs: release
50+
uses: ./.github/workflows/service_setup-matrix.yml
51+
permissions:
52+
contents: read
2553
with:
54+
ref: ${{ needs.release.outputs.tag }}
55+
56+
build:
57+
needs: [release, setup]
58+
name: build ${{ matrix.variation }}
59+
strategy:
60+
fail-fast: false
61+
matrix:
62+
variation: ${{ fromJson(needs.setup.outputs.variations) }}
63+
permissions:
64+
contents: read
65+
id-token: write
66+
uses: ./.github/workflows/service_build-images.yml
67+
with:
68+
variation: ${{ matrix.variation }}
69+
matrix: ${{ needs.setup.outputs.matrix }}
70+
ref: ${{ needs.release.outputs.tag }}
2671
registry-repositories: "docker.io/serversideup/php,ghcr.io/serversideup/php"
2772
tag-prefix: ''
2873
release-type: "latest"
29-
ref: ${{ needs.get-latest-release.outputs.release_tag }}
3074
secrets: inherit
75+
76+
test:
77+
needs: [release, setup, build]
78+
if: always() && needs.setup.result == 'success'
79+
uses: ./.github/workflows/service_test-images.yml
80+
permissions:
81+
contents: read
82+
id-token: write
83+
with:
84+
ref: ${{ needs.release.outputs.tag }}
85+
86+
# Only images that passed the image tests reach a public registry.
87+
publish:
88+
needs: [release, build, test]
89+
if: needs.build.result == 'success' && needs.test.result == 'success'
90+
uses: ./.github/workflows/service_publish-images.yml
91+
permissions:
92+
contents: read
93+
packages: write
94+
id-token: write
95+
with:
96+
ref: ${{ needs.release.outputs.tag }}
97+
secrets: inherit
98+
99+
report:
100+
needs: [release, setup, build, test, publish]
101+
if: always() && needs.setup.result == 'success'
102+
uses: ./.github/workflows/service_report.yml
103+
permissions:
104+
contents: read
105+
with:
106+
matrix: ${{ needs.setup.outputs.matrix }}
107+
ref: ${{ needs.release.outputs.tag }}

0 commit comments

Comments
 (0)