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

Adds s390x to always run on cpaas steps, and optionally on PRs #1339

Closed
wants to merge 18 commits into from
Closed
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
96 changes: 95 additions & 1 deletion .github/workflows/collector-full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,8 @@ jobs:
runs-on: ubuntu-latest
if: |
github.event_name == 'pull_request' &&
!contains(github.event.pull_request.labels.*.name, 'build-full-images')
!contains(github.event.pull_request.labels.*.name, 'build-full-images') &&
contains(github.event.pull_request.labels.*.name, 'run-multiarch-builds')
env:
COLLECTOR_IMAGE_SLIM: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}-slim

Expand Down Expand Up @@ -268,3 +269,96 @@ jobs:
dst-image: quay.io/rhacs-eng/collector:${{ inputs.collector-tag }}-latest
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

slim-multiarch-manifests:
runs-on: ubuntu-latest
if: |
github.event_name == 'pull_request' &&
!contains(github.event.pull_request.labels.*.name, 'build-full-images') &&
!contains(github.event.pull_request.labels.*.name, 'run-multiarch-builds')
env:
BASE_IMAGE: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}
ARCHS: amd64 ppc64le s390x

steps:
- uses: actions/checkout@v3

- name: Pull slim images
run: |
docker pull "${BASE_IMAGE}-amd64-slim"
docker pull "${BASE_IMAGE}-s390x-slim"
docker pull "${BASE_IMAGE}-ppc64le-slim"

- name: Login to quay.io/stackrox-io
uses: docker/login-action@v2
with:
registry: quay.io
username: ${{ secrets.QUAY_STACKROX_IO_RW_USERNAME }}
password: ${{ secrets.QUAY_STACKROX_IO_RW_PASSWORD }}

- name: Retag slim amd64
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-amd64-slim
dst-image: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}-amd64
username: ${{ secrets.QUAY_STACKROX_IO_RW_USERNAME }}
password: ${{ secrets.QUAY_STACKROX_IO_RW_PASSWORD }}

- name: Retag slim ppc64le
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-ppc64le-slim
dst-image: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}-ppc64le
username: ${{ secrets.QUAY_STACKROX_IO_RW_USERNAME }}
password: ${{ secrets.QUAY_STACKROX_IO_RW_PASSWORD }}

- name: Retag slim s390x
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-s390x-slim
dst-image: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}-s390x
username: ${{ secrets.QUAY_STACKROX_IO_RW_USERNAME }}
password: ${{ secrets.QUAY_STACKROX_IO_RW_PASSWORD }}

- name: Create multi-arch manifest stackrox-io
uses: ./.github/actions/create-multiarch-manifest
with:
base-image: quay.io/stackrox-io/collector:${{ inputs.collector-tag }}
archs: ${{ env.ARCHS }}

- name: Retag slim amd64
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-amd64-slim
dst-image: quay.io/rhacs-eng/collector:${{ inputs.collector-tag }}-amd64
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

- name: Retag slim ppc64le
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-ppc64le-slim
dst-image: quay.io/rhacs-eng/collector:${{ inputs.collector-tag }}-ppc64le
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

- name: Retag slim s390x
uses: stackrox/actions/images/retag-and-push@v1
with:
src-image: ${{ env.BASE_IMAGE }}-s390x-slim
dst-image: quay.io/rhacs-eng/collector:${{ inputs.collector-tag }}-s390x
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

- name: Login to quay.io/rhacs-eng
uses: docker/login-action@v2
with:
registry: quay.io
username: ${{ secrets.QUAY_RHACS_ENG_RW_USERNAME }}
password: ${{ secrets.QUAY_RHACS_ENG_RW_PASSWORD }}

- name: Create multi-arch manifest rhacs-eng
uses: ./.github/actions/create-multiarch-manifest
with:
base-image: quay.io/rhacs-eng/collector:${{ inputs.collector-tag }}
archs: ${{ env.ARCHS }}
2 changes: 1 addition & 1 deletion .github/workflows/cpaas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ jobs:
vm_type:
- rhel
- rhel-sap
- rhel-s390x
with:
vm_type: ${{ matrix.vm_type }}
collector-tag: ${{ needs.init.outputs.collector-tag }}-cpaas
Expand All @@ -121,7 +122,6 @@ jobs:
fail-fast: false
matrix:
vm_type:
- rhel-s390x
- rhel-ppc64le
with:
vm_type: ${{ matrix.vm_type }}
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,13 @@ on:
Tag used for QA containers
type: string
required: true

multi-arch-tests:
description: |
whether to run multi-arch testing
type: boolean
required: true

job-tag:
description: |
Used to differentiate between different sources when creating
Expand Down Expand Up @@ -63,6 +70,21 @@ jobs:
job-tag: ${{ inputs.job-tag }}
secrets: inherit

multi-arch-integration-tests:
uses: ./.github/workflows/integration-tests-vm-type.yml
if: inputs.multi-arch-tests
strategy:
fail-fast: false
matrix:
vm_type:
- rhel-s390x
with:
vm_type: ${{ matrix.vm_type }}
collector-tag: ${{ inputs.collector-tag }}
collector-qa-tag: ${{ inputs.collector-qa-tag }}
job-tag: ${{ inputs.job-tag }}
secrets: inherit

notify:
runs-on: ubuntu-latest
if: always() && contains(join(needs.*.result, ','), 'failure') && github.event_name == 'push'
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ jobs:
with:
collector-tag: ${{ needs.init.outputs.collector-tag }}
collector-qa-tag: ${{ needs.init.outputs.collector-qa-tag }}
multi-arch-tests: |
${{ github.event_name == 'push' || contains(github.event.pull_request.labels.*.name, 'run-multiarch-builds') }}
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-integration-tests') }}
needs:
- init
Expand Down
Loading