Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
2121f3b
Add workflow to validate UBI images pass RedHat Certification
shaun-nx Oct 7, 2025
d61c9f4
Update args and fix pre-commit checks
shaun-nx Oct 7, 2025
2ffc89c
Add premissions and default run env
shaun-nx Oct 7, 2025
34d29e7
Ensure Openshift ceritfication runs outside of prod release
shaun-nx Oct 7, 2025
11cb2ec
Update dry_run input
shaun-nx Oct 7, 2025
c132f47
Ensure Openshift certification runs only on merges to main, and durin…
shaun-nx Oct 7, 2025
7597193
Potential fix for code scanning alert no. 542: If expression always true
shaun-nx Oct 7, 2025
9691208
tmp remove if check for certification job
shaun-nx Oct 7, 2025
bb8a349
Remove `--json` flag
shaun-nx Oct 7, 2025
f164607
Use check container instead of check operator
shaun-nx Oct 7, 2025
8d908cf
Add steps to save and tag docker images for use by preflight checks
shaun-nx Oct 7, 2025
afc676e
change operator to container
shaun-nx Oct 7, 2025
8ef4adb
Move image save and upload to build.yaml. Add debug echo for tags
shaun-nx Oct 8, 2025
118145b
Update openshift certification job with new image tags
shaun-nx Oct 8, 2025
aafd707
Fix pre-commit errors
shaun-nx Oct 8, 2025
893fdb1
Load images to Docker Daemon in build step. Run Openshift certificati…
shaun-nx Oct 8, 2025
60388bb
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 8, 2025
9a16ec5
Add image to input
shaun-nx Oct 8, 2025
90f1618
Remove image version output
shaun-nx Oct 8, 2025
ff72dc3
Use docker buildx to ensure images for multi platforms are saved
shaun-nx Oct 8, 2025
ff3b959
Fix pre-commit errors
shaun-nx Oct 8, 2025
e76b660
Ensure image_version is passed to opernshift certification
shaun-nx Oct 8, 2025
b9cf4aa
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 8, 2025
cb8d8f9
Add image_version to inputs
shaun-nx Oct 8, 2025
a9d3eb9
Remove platform option
shaun-nx Oct 8, 2025
7d185bf
Remove platform from `with`
shaun-nx Oct 8, 2025
4fbeed6
Log into container reg to upload images
shaun-nx Oct 8, 2025
6f9f14b
Add debugging echo for tags
shaun-nx Oct 8, 2025
912a3ff
Only export and upload UBI images
shaun-nx Oct 8, 2025
5064ef6
Fix inputs
shaun-nx Oct 8, 2025
a219d77
Fix export step
shaun-nx Oct 8, 2025
afc4c36
Debug docker buildx
shaun-nx Oct 8, 2025
e0b7b9a
Update Buildx step
shaun-nx Oct 8, 2025
fd02d12
Debug export command
shaun-nx Oct 8, 2025
ce3f4c6
Use docker save instead of buildx
shaun-nx Oct 8, 2025
f5adba0
Change load command and if check for saving
shaun-nx Oct 8, 2025
9cbee53
Fix yamllint errors
shaun-nx Oct 8, 2025
d75ade3
Move tarball to workspace root
shaun-nx Oct 8, 2025
4fad413
Update mv command
shaun-nx Oct 8, 2025
aeb55e6
Debug downloaded artifacts
shaun-nx Oct 8, 2025
decd459
Remove mv step
shaun-nx Oct 8, 2025
0db0eff
Update Checkout Repository command
shaun-nx Oct 9, 2025
8decbcb
Add tag and dry_run input
shaun-nx Oct 9, 2025
83e216d
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 9, 2025
e45fb54
Debug artifact upload and download
shaun-nx Oct 9, 2025
b75a370
Fix pre-commit errors
shaun-nx Oct 9, 2025
887362e
Update upload step
shaun-nx Oct 9, 2025
113e43b
Fix artifact name
shaun-nx Oct 9, 2025
bd667db
Fix artifact name
shaun-nx Oct 9, 2025
109a18d
Change name format
shaun-nx Oct 9, 2025
889ba70
Fix upload name
shaun-nx Oct 9, 2025
c6838b2
Re add steps to load and run preflight tool
shaun-nx Oct 9, 2025
ee1d63d
Add image tags for quay.io
shaun-nx Oct 9, 2025
8f3cfc0
temp: allow images to be pushed to quay.io during PRs
shaun-nx Oct 9, 2025
dad38c0
Add quay login to build.yml
shaun-nx Oct 9, 2025
7354392
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 9, 2025
59857e6
Update preflight run step
shaun-nx Oct 9, 2025
a02fbe8
Fix indentation
shaun-nx Oct 9, 2025
c7f2ab9
Add logout: false
shaun-nx Oct 9, 2025
ed6878a
Fix run preflight command
shaun-nx Oct 9, 2025
e1003bc
Fix image name
shaun-nx Oct 9, 2025
5a252d8
Ensure only UBI images are pushed to quay.io
shaun-nx Oct 9, 2025
a2d4762
Update images and preflight run step
shaun-nx Oct 9, 2025
de68998
Fix yamllint
shaun-nx Oct 9, 2025
21ac62b
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 9, 2025
a351f50
Fix image reference
shaun-nx Oct 9, 2025
bb98927
Apped ubi to image version
shaun-nx Oct 9, 2025
8abbf61
Ensure correct tags are passed to preflight job
shaun-nx Oct 9, 2025
a6bc92f
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 9, 2025
695c5b6
Fix `if` check in certification job
shaun-nx Oct 9, 2025
5100b57
Fix image version input
shaun-nx Oct 9, 2025
b7482df
Add operator to image version
shaun-nx Oct 9, 2025
2eb9464
Run preflight checks on images pushed to ghcr.io and only run checks …
shaun-nx Oct 9, 2025
42bdd4d
Test against existing edge ghcr images
shaun-nx Oct 10, 2025
d451e1b
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 10, 2025
c49f43c
Remove duplicate step
shaun-nx Oct 10, 2025
36b1430
Test: Run openshift certification on PRs
shaun-nx Oct 10, 2025
fc1c94d
Fix EOF error
shaun-nx Oct 10, 2025
02fd063
Fix variable
shaun-nx Oct 10, 2025
bd33296
Fix repo
shaun-nx Oct 10, 2025
1ff669b
Enaure we can log into reg
shaun-nx Oct 10, 2025
7a5d894
Add platform to matrix
shaun-nx Oct 10, 2025
cf0dc37
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 10, 2025
ee43213
Add platform to inputs
shaun-nx Oct 10, 2025
76e9317
Update platforms in matrix
shaun-nx Oct 10, 2025
9697b76
Ensure openshift certificaiton only runs on merges to main and releases
shaun-nx Oct 10, 2025
022c27a
Merge branch 'main' into feat/pipeline-certfication-testing
shaun-nx Oct 10, 2025
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
5 changes: 5 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ on:
required: false
type: string
default: 'ubuntu-24.04'
outputs:
image_version:
value: ${{ jobs.build.outputs.image_version }}

defaults:
run:
Expand All @@ -41,6 +44,8 @@ jobs:
packages: write # for docker/build-push-action to push to GHCR
id-token: write # for docker/login to login to NGINX registry
runs-on: ${{ inputs.runner }}
outputs:
image_version: ${{ steps.meta.outputs.version }}
services:
registry:
image: registry:3
Expand Down
23 changes: 22 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@
platforms: ${{ matrix.platforms }}
build-os: ${{ matrix.build-os }}
tag: ${{ inputs.release_version || '' }}
dry_run: ${{ inputs.dry_run || false}}
dry_run: ${{ inputs.dry_run || false }}
runner: ${{ github.repository_owner == 'nginx' && (inputs.is_production_release || (github.event_name == 'push' && github.ref == 'refs/heads/main')) && 'ubuntu-24.04-amd64' || 'ubuntu-24.04' }}
permissions:
contents: read # for docker/build-push-action to read repo content
Expand Down Expand Up @@ -407,6 +407,27 @@
id-token: write # for docker/login to login to NGINX registry
secrets: inherit

openshift-certification:
name: OpenShift Certification
needs: [build-oss, build-operator]
strategy:
fail-fast: false
matrix:
image: [ngf, nginx, operator]
platform: ["amd64", "arm64"]
if: ${{ github.event_name != 'pull_request' && github.event_pull_request.base.ref == 'main' || (github.event_name == 'push' && github.ref == 'refs/heads/main') || (inputs.is_production_release == true) }}

Check failure on line 418 in .github/workflows/ci.yml

View workflow job for this annotation

GitHub Actions / Actionlint

[actionlint] reported by reviewdog 🐶 property "event_pull_request" is not defined in object type {action: string; action_path: string; action_ref: string; action_repository: string; action_status: string; actor: string; actor_id: string; api_url: string; artifact_cache_size_limit: number; base_ref: string; env: string; event: object; event_name: string; event_path: string; graphql_url: string; head_ref: string; job: string; output: string; path: string; ref: string; ref_name: string; ref_protected: bool; ref_type: string; repository: string; repository_id: string; repository_owner: string; repository_owner_id: string; repository_visibility: string; repositoryurl: string; retention_days: number; run_attempt: string; run_id: string; run_number: string; secret_source: string; server_url: string; sha: string; state: string; step_summary: string; token: string; triggering_actor: string; workflow: string; workflow_ref: string; workflow_sha: string; workspace: string} [expression] Raw Output: e:.github/workflows/ci.yml:418:52: property "event_pull_request" is not defined in object type {action: string; action_path: string; action_ref: string; action_repository: string; action_status: string; actor: string; actor_id: string; api_url: string; artifact_cache_size_limit: number; base_ref: string; env: string; event: object; event_name: string; event_path: string; graphql_url: string; head_ref: string; job: string; output: string; path: string; ref: string; ref_name: string; ref_protected: bool; ref_type: string; repository: string; repository_id: string; repository_owner: string; repository_owner_id: string; repository_visibility: string; repositoryurl: string; retention_days: number; run_attempt: string; run_id: string; run_number: string; secret_source: string; server_url: string; sha: string; state: string; step_summary: string; token: string; triggering_actor: string; workflow: string; workflow_ref: string; workflow_sha: string; workspace: string} [expression]
uses: ./.github/workflows/openshift-certification.yml
with:
image: ${{ matrix.image }}
platform: ${{ matrix.platform }}
tag: ${{ inputs.release_version || '' }}
dry_run: ${{ inputs.dry_run || false }}
image_version: ${{ (matrix.image == 'ngf' && endsWith(needs.build-oss.outputs.image_version, '-ubi')) && needs.build-oss.outputs.image_version || (matrix.image == 'nginx' && endsWith(needs.build-oss.outputs.image_version, '-ubi')) && needs.build-oss.outputs.image_version || (matrix.image == 'operator' && needs.build-operator.outputs.image_version) }}
permissions:
contents: read
packages: read
secrets: inherit

functional-tests:
name: Functional tests
needs: [vars, build-oss, build-plus]
Expand Down
73 changes: 73 additions & 0 deletions .github/workflows/openshift-certification.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: OpenShift Certification

on:
workflow_call:
inputs:
image:
required: true
type: string
platform:
required: true
type: string
image_version:
required: true
type: string
tag:
required: false
type: string
default: ''
dry_run:
required: false
type: boolean
default: false

defaults:
run:
shell: bash

permissions:
contents: read

jobs:
preflight:
runs-on: ubuntu-24.04
steps:
- name: Checkout Repository
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
ref: ${{ (inputs.tag != '' && !inputs.dry_run ) && format('refs/tags/v{0}', inputs.tag) || github.ref }}

- name: Login to GitHub Container Registry
uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef # v3.6.0
if: ${{ github.event_name != 'pull_request' && ! contains(inputs.image, 'plus') }}
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Download preflight binary
run: |
curl -LO https://github.com/redhat-openshift-ecosystem/openshift-preflight/releases/latest/download/preflight-linux-amd64
chmod +x preflight-linux-amd64
sudo mv preflight-linux-amd64 /usr/local/bin/preflight

- name: Run preflight
env:
PYXIS_API_TOKEN: ${{ secrets.PYXIS_API_TOKEN }}
run: |
if [[ "${{ inputs.image }}" == "ngf" ]]; then
IMAGE_PATH="ghcr.io/${{ github.repository_owner }}/nginx-gateway-fabric:${{ inputs.image_version }}"
else
IMAGE_PATH="ghcr.io/${{ github.repository_owner }}/nginx-gateway-fabric/${{ inputs.image }}:${{ inputs.image_version }}"
fi
preflight check container "$IMAGE_PATH" --platform ${{ inputs.platform }} > preflight-result.json

- name: Check preflight results
run: |
failed_count=$(jq '.results.failed | length' preflight-result.json)
if [ "$failed_count" -ne 0 ]; then
echo "Preflight checks failed: $failed_count failed checks"
echo "Results for preflight-result.json:"
jq '.results.failed' preflight-result.json
exit 1
fi
Loading