From a133e3242136b31b5f4697dad3fe097a0674f397 Mon Sep 17 00:00:00 2001 From: "Daniel A. Wozniak" Date: Tue, 5 Nov 2024 15:04:24 -0700 Subject: [PATCH] Add rockylinux containers --- .github/workflows/ci.yml | 98 +++++++++++++++++++ .github/workflows/nightly.yml | 96 ++++++++++++++++++ .github/workflows/scheduled.yml | 96 ++++++++++++++++++ .github/workflows/staging.yml | 96 ++++++++++++++++++ .../templates/test-salt-pkg.yml.jinja | 1 + .../workflows/templates/test-salt.yml.jinja | 1 + .github/workflows/test-action-linux.yml | 6 +- .../workflows/test-packages-action-linux.yml | 15 ++- .../test-packages-action-windows.yml | 2 +- tools/precommit/workflows.py | 54 ++++++---- tools/utils/__init__.py | 1 + 11 files changed, 444 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 74287003fc4..bf63a4d5058 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -604,6 +604,50 @@ jobs: nox-archive-hash: "${{ needs.prepare-workflow.outputs.nox-archive-hash }}" kind: windows + rockylinux-9-pkg-tests: + name: Rocky Linux 9 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: ${{ fromJSON(needs.prepare-workflow.outputs.testrun)['skip_code_coverage'] }} + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + + rockylinux-9-arm64-pkg-tests: + name: Rocky Linux 9 Arm64 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] && contains(fromJSON(needs.prepare-workflow.outputs.os-labels), 'rockylinux-9-arm64') }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: ${{ fromJSON(needs.prepare-workflow.outputs.testrun)['skip_code_coverage'] }} + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + ubuntu-2204-pkg-tests: name: Ubuntu 22.04 Package Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] && contains(fromJSON(needs.prepare-workflow.outputs.os-labels), 'ubuntu-22.04') }} @@ -616,6 +660,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -637,6 +682,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -816,6 +862,50 @@ jobs: workflow-slug: ci default-timeout: 180 + rockylinux-9: + name: Rocky Linux 9 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: ${{ fromJSON(needs.prepare-workflow.outputs.testrun)['skip_code_coverage'] }} + workflow-slug: ci + default-timeout: 180 + + rockylinux-9-arm64: + name: Rocky Linux 9 Arm64 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] && contains(fromJSON(needs.prepare-workflow.outputs.os-labels), 'rockylinux-9-arm64') }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: ${{ fromJSON(needs.prepare-workflow.outputs.testrun)['skip_code_coverage'] }} + workflow-slug: ci + default-timeout: 180 + ubuntu-2204: name: Ubuntu 22.04 Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] && contains(fromJSON(needs.prepare-workflow.outputs.os-labels), 'ubuntu-22.04') }} @@ -827,6 +917,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -848,6 +939,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -872,6 +964,8 @@ jobs: - windows-2019 - windows-2022 - macos-12 + - rockylinux-9 + - rockylinux-9-arm64 - ubuntu-2204 - ubuntu-2204-arm64 steps: @@ -1019,8 +1113,12 @@ jobs: - windows-2019 - windows-2022 - macos-12 + - rockylinux-9 + - rockylinux-9-arm64 - ubuntu-2204 - ubuntu-2204-arm64 + - rockylinux-9-pkg-tests + - rockylinux-9-arm64-pkg-tests - ubuntu-2204-pkg-tests - ubuntu-2204-arm64-pkg-tests - macos-12-pkg-tests diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 28a5b78dd08..e527c382ac7 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -727,6 +727,50 @@ jobs: nox-archive-hash: "${{ needs.prepare-workflow.outputs.nox-archive-hash }}" kind: windows + rockylinux-9-pkg-tests: + name: Rocky Linux 9 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + + rockylinux-9-arm64-pkg-tests: + name: Rocky Linux 9 Arm64 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + ubuntu-2204-pkg-tests: name: Ubuntu 22.04 Package Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -739,6 +783,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -760,6 +805,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -939,6 +985,50 @@ jobs: workflow-slug: nightly default-timeout: 360 + rockylinux-9: + name: Rocky Linux 9 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: nightly + default-timeout: 360 + + rockylinux-9-arm64: + name: Rocky Linux 9 Arm64 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: nightly + default-timeout: 360 + ubuntu-2204: name: Ubuntu 22.04 Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -950,6 +1040,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -971,6 +1062,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -1732,6 +1824,8 @@ jobs: - windows-2019 - windows-2022 - macos-12 + - rockylinux-9 + - rockylinux-9-arm64 - ubuntu-2204 - ubuntu-2204-arm64 @@ -1798,6 +1892,8 @@ jobs: - build-pkgs-src-macos - build-pkgs-src-windows - publish-repositories + - rockylinux-9-pkg-tests + - rockylinux-9-arm64-pkg-tests - ubuntu-2204-pkg-tests - ubuntu-2204-arm64-pkg-tests - macos-12-pkg-tests diff --git a/.github/workflows/scheduled.yml b/.github/workflows/scheduled.yml index 38cd955944e..fae838e47d7 100644 --- a/.github/workflows/scheduled.yml +++ b/.github/workflows/scheduled.yml @@ -643,6 +643,50 @@ jobs: nox-archive-hash: "${{ needs.prepare-workflow.outputs.nox-archive-hash }}" kind: windows + rockylinux-9-pkg-tests: + name: Rocky Linux 9 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + + rockylinux-9-arm64-pkg-tests: + name: Rocky Linux 9 Arm64 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + ubuntu-2204-pkg-tests: name: Ubuntu 22.04 Package Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -655,6 +699,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -676,6 +721,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -855,6 +901,50 @@ jobs: workflow-slug: scheduled default-timeout: 360 + rockylinux-9: + name: Rocky Linux 9 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: scheduled + default-timeout: 360 + + rockylinux-9-arm64: + name: Rocky Linux 9 Arm64 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: scheduled + default-timeout: 360 + ubuntu-2204: name: Ubuntu 22.04 Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -866,6 +956,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -887,6 +978,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -923,8 +1015,12 @@ jobs: - windows-2019 - windows-2022 - macos-12 + - rockylinux-9 + - rockylinux-9-arm64 - ubuntu-2204 - ubuntu-2204-arm64 + - rockylinux-9-pkg-tests + - rockylinux-9-arm64-pkg-tests - ubuntu-2204-pkg-tests - ubuntu-2204-arm64-pkg-tests - macos-12-pkg-tests diff --git a/.github/workflows/staging.yml b/.github/workflows/staging.yml index 31a488fea6c..afb691abd87 100644 --- a/.github/workflows/staging.yml +++ b/.github/workflows/staging.yml @@ -709,6 +709,50 @@ jobs: nox-archive-hash: "${{ needs.prepare-workflow.outputs.nox-archive-hash }}" kind: windows + rockylinux-9-pkg-tests: + name: Rocky Linux 9 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + + rockylinux-9-arm64-pkg-tests: + name: Rocky Linux 9 Arm64 Package Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-pkgs-onedir-linux + - build-ci-deps-linux + uses: ./.github/workflows/test-packages-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + pkg-type: rpm + nox-version: 2022.8.7 + python-version: "3.10" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + testing-releases: ${{ needs.prepare-workflow.outputs.testing-releases }} + ubuntu-2204-pkg-tests: name: Ubuntu 22.04 Package Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test-pkg'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -721,6 +765,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -742,6 +787,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: deb @@ -921,6 +967,50 @@ jobs: workflow-slug: staging default-timeout: 180 + rockylinux-9: + name: Rocky Linux 9 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: x86_64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: staging + default-timeout: 180 + + rockylinux-9-arm64: + name: Rocky Linux 9 Arm64 Test + if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} + needs: + - prepare-workflow + - build-ci-deps-linux + uses: ./.github/workflows/test-action-linux.yml + with: + distro-slug: rockylinux-9-arm64 + nox-session: ci-test-onedir + platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9 + arch: arm64 + nox-version: 2022.8.7 + gh-actions-python-version: "3.10" + testrun: ${{ needs.prepare-workflow.outputs.testrun }} + salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" + cache-prefix: ${{ needs.prepare-workflow.outputs.cache-seed }}|3.10.15 + skip-code-coverage: true + workflow-slug: staging + default-timeout: 180 + ubuntu-2204: name: Ubuntu 22.04 Test if: ${{ fromJSON(needs.prepare-workflow.outputs.jobs)['test'] && fromJSON(needs.prepare-workflow.outputs.runners)['self-hosted'] }} @@ -932,6 +1022,7 @@ jobs: distro-slug: ubuntu-22.04 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: x86_64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -953,6 +1044,7 @@ jobs: distro-slug: ubuntu-22.04-arm64 nox-session: ci-test-onedir platform: linux + container: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 arch: arm64 nox-version: 2022.8.7 gh-actions-python-version: "3.10" @@ -1844,8 +1936,12 @@ jobs: - windows-2019 - windows-2022 - macos-12 + - rockylinux-9 + - rockylinux-9-arm64 - ubuntu-2204 - ubuntu-2204-arm64 + - rockylinux-9-pkg-tests + - rockylinux-9-arm64-pkg-tests - ubuntu-2204-pkg-tests - ubuntu-2204-arm64-pkg-tests - macos-12-pkg-tests diff --git a/.github/workflows/templates/test-salt-pkg.yml.jinja b/.github/workflows/templates/test-salt-pkg.yml.jinja index 2fd4e3c802b..362c74cfa02 100644 --- a/.github/workflows/templates/test-salt-pkg.yml.jinja +++ b/.github/workflows/templates/test-salt-pkg.yml.jinja @@ -18,6 +18,7 @@ distro-slug: <{ os.slug }> nox-session: ci-test-onedir platform: linux + container: <{ os.container }> arch: <{ os.arch }> salt-version: "${{ needs.prepare-workflow.outputs.salt-version }}" pkg-type: <{ os.pkg_type }> diff --git a/.github/workflows/templates/test-salt.yml.jinja b/.github/workflows/templates/test-salt.yml.jinja index cb9bd0fbc35..5699337ef2e 100644 --- a/.github/workflows/templates/test-salt.yml.jinja +++ b/.github/workflows/templates/test-salt.yml.jinja @@ -85,6 +85,7 @@ distro-slug: <{ os.slug }> nox-session: ci-test-onedir platform: linux + container: <{ os.container }> arch: <{ os.arch }> nox-version: <{ nox_version }> gh-actions-python-version: "<{ gh_actions_workflows_python_version }>" diff --git a/.github/workflows/test-action-linux.yml b/.github/workflows/test-action-linux.yml index 3c813636fad..b29c0191ff4 100644 --- a/.github/workflows/test-action-linux.yml +++ b/.github/workflows/test-action-linux.yml @@ -12,6 +12,10 @@ on: required: true type: string description: The nox session to run + container: + required: true + type: string + description: The container image to run tests on testrun: required: true type: string @@ -112,7 +116,7 @@ jobs: name: Test runs-on: linux-${{ inputs.arch }} container: - image: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 + image: ${{ inputs.container }} # Full test runs. Each chunk should never take more than 2 hours. # Partial test runs(no chunk parallelization), 6 Hours timeout-minutes: ${{ fromJSON(inputs.testrun)['type'] == 'full' && inputs.default-timeout || 360 }} diff --git a/.github/workflows/test-packages-action-linux.yml b/.github/workflows/test-packages-action-linux.yml index df7d3c1acb1..446bec2dd20 100644 --- a/.github/workflows/test-packages-action-linux.yml +++ b/.github/workflows/test-packages-action-linux.yml @@ -11,6 +11,10 @@ on: required: true type: string description: The platform being tested + container: + required: true + type: string + description: The container image to run tests on arch: required: true type: string @@ -107,7 +111,7 @@ jobs: runs-on: - linux-${{ inputs.arch }} container: - image: ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04 + image: ${{ inputs.container }} timeout-minutes: 120 # 2 Hours - More than this and something is wrong needs: @@ -208,6 +212,15 @@ jobs: nox --force-color -e ${{ inputs.nox-session }}-pkgs -- ${{ matrix.tests-chunk }} \ ${{ matrix.version && format('--prev-version={0}', matrix.version) || ''}} + - name: Upload Test Run Log Artifacts + if: always() + uses: actions/upload-artifact@v4 + with: + name: pkg-testrun-log-artifacts-${{ inputs.distro-slug }}-${{ inputs.nox-session }}-${{ matrix.transport }}-${{ matrix.tests-chunk }}-${{ env.TIMESTAMP }} + path: | + artifacts/logs + include-hidden-files: true + - name: Upload Test Run Artifacts if: always() uses: actions/upload-artifact@v4 diff --git a/.github/workflows/test-packages-action-windows.yml b/.github/workflows/test-packages-action-windows.yml index 8ecda36d33d..cca00a17c45 100644 --- a/.github/workflows/test-packages-action-windows.yml +++ b/.github/workflows/test-packages-action-windows.yml @@ -229,7 +229,7 @@ jobs: fi - name: Upload Test Run Log Artifacts - if: always() && steps.download-artifacts-from-vm.outcome == 'success' + if: always() uses: actions/upload-artifact@v4 with: name: pkg-testrun-log-artifacts-${{ inputs.distro-slug }}-${{ inputs.nox-session }}-${{ matrix.transport }}-${{ matrix.tests-chunk }}-${{ env.TIMESTAMP }} diff --git a/tools/precommit/workflows.py b/tools/precommit/workflows.py index b677c21e017..cacfb2f89a6 100644 --- a/tools/precommit/workflows.py +++ b/tools/precommit/workflows.py @@ -29,12 +29,18 @@ TEST_SALT_LISTING = PlatformDefinitions( # display_name="Rocky Linux 8 Arm64", # arch="arm64", # ), - # Linux(slug="rockylinux-9", display_name="Rocky Linux 9", arch="x86_64"), - # Linux( - # slug="rockylinux-9-arm64", - # display_name="Rocky Linux 9 Arm64", - # arch="arm64", - # ), + Linux( + slug="rockylinux-9", + display_name="Rocky Linux 9", + arch="x86_64", + container="ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9", + ), + Linux( + slug="rockylinux-9-arm64", + display_name="Rocky Linux 9 Arm64", + arch="arm64", + container="ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9", + ), # Linux(slug="amazonlinux-2", display_name="Amazon Linux 2", arch="x86_64"), # Linux( # slug="amazonlinux-2-arm64", @@ -95,11 +101,17 @@ TEST_SALT_LISTING = PlatformDefinitions( # display_name="Ubuntu 20.04 Arm64", # arch="arm64", # ), - Linux(slug="ubuntu-22.04", display_name="Ubuntu 22.04", arch="x86_64"), + Linux( + slug="ubuntu-22.04", + display_name="Ubuntu 22.04", + arch="x86_64", + container="ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04", + ), Linux( slug="ubuntu-22.04-arm64", display_name="Ubuntu 22.04 Arm64", arch="arm64", + container="ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04", ), # Linux(slug="ubuntu-24.04", display_name="Ubuntu 24.04", arch="x86_64"), # Linux( @@ -207,18 +219,20 @@ def generate_workflows(ctx: Context): # arch="arm64", # pkg_type="rpm", # ), - # Linux( - # slug="rockylinux-9", - # display_name="Rocky Linux 9", - # arch="x86_64", - # pkg_type="rpm", - # ), - # Linux( - # slug="rockylinux-9-arm64", - # display_name="Rocky Linux 9 Arm64", - # arch="arm64", - # pkg_type="rpm", - # ), + Linux( + slug="rockylinux-9", + display_name="Rocky Linux 9", + arch="x86_64", + pkg_type="rpm", + container="ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9", + ), + Linux( + slug="rockylinux-9-arm64", + display_name="Rocky Linux 9 Arm64", + arch="arm64", + pkg_type="rpm", + container="ghcr.io/saltstack/salt-ci-containers/testing:rockylinux-9", + ), # Linux( # slug="amazonlinux-2", # display_name="Amazon Linux 2", @@ -336,12 +350,14 @@ def generate_workflows(ctx: Context): display_name="Ubuntu 22.04", arch="x86_64", pkg_type="deb", + container="ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04", ), Linux( slug="ubuntu-22.04-arm64", display_name="Ubuntu 22.04 Arm64", arch="arm64", pkg_type="deb", + container="ghcr.io/saltstack/salt-ci-containers/testing:ubuntu-22.04", ), # Linux( # slug="ubuntu-24.04", diff --git a/tools/utils/__init__.py b/tools/utils/__init__.py index 7588a183eef..3b3d22323e6 100644 --- a/tools/utils/__init__.py +++ b/tools/utils/__init__.py @@ -67,6 +67,7 @@ class OS: class Linux(OS): platform: str = attr.ib(default="linux") fips: bool = attr.ib(default=False) + container: str = attr.ib(default=None) @attr.s(frozen=True, slots=True)