Repository navigation
Build on interim patched PHP base images and drop PHP 8.1 #21
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
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| --- | ||
| name: "build interim service-cli images" | ||
|
|
||
| # Temporary: builds docksal/cli from the phase2/service-cli fork until | ||
| # https://github.com/docksal/service-cli/pull/350 is merged and released. | ||
|
|
||
| on: | ||
| workflow_dispatch: | ||
| schedule: | ||
| - cron: '0 10 * * 0' # Every Sunday at 10AM | ||
|
|
||
| permissions: | ||
| contents: read | ||
| packages: write | ||
|
|
||
| env: | ||
| IMAGE: ghcr.io/${{ github.repository_owner }}/service-cli | ||
| SOURCE_REPO: phase2/service-cli | ||
| SOURCE_REF: phase2-interim | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
|
|
||
| jobs: | ||
| build: | ||
| name: "Build: ${{ matrix.version }}/${{ matrix.arch }}" | ||
| runs-on: ${{ matrix.runner }} | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| version: ["8.2", "8.3", "8.4"] | ||
| arch: [amd64, arm64] | ||
| include: | ||
| - arch: amd64 | ||
| runner: ubuntu-24.04 | ||
| - arch: arm64 | ||
| runner: ubuntu-24.04-arm | ||
|
|
||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v6 | ||
| with: | ||
| repository: ${{ env.SOURCE_REPO }} | ||
| ref: ${{ env.SOURCE_REF }} | ||
|
|
||
| - name: Login to GitHub Container Registry | ||
| uses: docker/login-action@v4 | ||
| with: | ||
| registry: ghcr.io | ||
| username: ${{ github.actor }} | ||
| password: ${{ secrets.GITHUB_TOKEN }} | ||
|
|
||
| - name: Build | ||
| uses: docker/build-push-action@v7 | ||
| with: | ||
| context: ${{ matrix.version }} | ||
| file: ${{ matrix.version }}/Dockerfile | ||
| build-args: VERSION=${{ matrix.version }} | ||
| tags: ${{ env.IMAGE }}:php${{ matrix.version }}-${{ matrix.arch }} | ||
| push: true | ||
| pull: true | ||
| no-cache: true | ||
|
|
||
| push: | ||
| name: "Push: ${{ matrix.version }}/multi" | ||
| runs-on: ubuntu-24.04 | ||
| needs: build | ||
|
|
||
| strategy: | ||
| matrix: | ||
| version: ["8.2", "8.3", "8.4"] | ||
|
|
||
| steps: | ||
| - name: Login to GitHub Container Registry | ||
| uses: docker/login-action@v4 | ||
| with: | ||
| registry: ghcr.io | ||
| username: ${{ github.actor }} | ||
| password: ${{ secrets.GITHUB_TOKEN }} | ||
|
|
||
| - name: Push multi-arch image | ||
| run: | | ||
| docker buildx imagetools create -t "${IMAGE}:php${{ matrix.version }}" \ | ||
| "${IMAGE}:php${{ matrix.version }}-amd64" \ | ||
| "${IMAGE}:php${{ matrix.version }}-arm64" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
Make the interim image readable before switching every build to it.
Pull-request builds skip GHCR login, and a newly published GHCR package is private by default. The supplied pipeline logs show anonymous pulls failing with HTTP 403 for the new base image. Publish the package and set its visibility to public before enabling this override, or provide pull-request builds with authorized read access. Otherwise, publishing the interim tags alone will not restore PR builds. (docs.github.com)
🧰 Tools
🪛 zizmor (1.30.1)
[warning] 19-97: overly broad permissions (excessive-permissions): default permissions used due to no permissions: block
(excessive-permissions)
🤖 Prompt for AI Agents
Source: Pipeline failures
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. This is expected until the package exists. After merge, the interim workflow will be run manually and the
service-clipackage made public (see the "After merge" steps in the PR description). Making it public is preferable to logging in on PR builds, since fork PRs couldn't read a private package anyway.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tekante Thanks for clarifying. The documented post-merge steps cover this finding; no PR-build login change is needed.
After publishing the package and making it public, verify anonymous pulls for
php8.2,php8.3, andphp8.4before rerunning “build images.” That verification remains pending.You are interacting with an AI system.