From c7e11a76370d9d6e9755986692ae909a3b2f8d1b Mon Sep 17 00:00:00 2001 From: David Murphy Date: Fri, 8 Nov 2024 08:59:06 -0700 Subject: [PATCH] Using Salt CI containers, removed OSs not supported by them --- .github/workflows/ci.yml | 126 +++++++----------------- .github/workflows/templates/generate.py | 105 ++++++++------------ .github/workflows/test-linux.yml | 4 +- bootstrap-salt.sh | 32 +++--- 4 files changed, 91 insertions(+), 176 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 91e8d2c..8139bbf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -161,35 +161,7 @@ jobs: - almalinux-8: - name: AlmaLinux 8 - if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' - uses: ./.github/workflows/test-linux.yml - needs: - - lint - - generate-actions-workflow - with: - distro-slug: almalinux-8 - display-name: AlmaLinux 8 - timeout: 20 - instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "latest", "default"]' - - - almalinux-9: - name: AlmaLinux 9 - if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' - uses: ./.github/workflows/test-linux.yml - needs: - - lint - - generate-actions-workflow - with: - distro-slug: almalinux-9 - display-name: AlmaLinux 9 - timeout: 20 - instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - - - amazon-2: + amazonlinux-2: name: Amazon 2 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' uses: ./.github/workflows/test-linux.yml @@ -197,24 +169,24 @@ jobs: - lint - generate-actions-workflow with: - distro-slug: amazon-2 + distro-slug: amazonlinux-2 display-name: Amazon 2 timeout: 20 instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "latest", "default"]' - centos-stream9: - name: CentOS Stream 9 + amazonlinux-2023: + name: Amazon 2023 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' uses: ./.github/workflows/test-linux.yml needs: - lint - generate-actions-workflow with: - distro-slug: centos-stream9 - display-name: CentOS Stream 9 + distro-slug: amazonlinux-2023 + display-name: Amazon 2023 timeout: 20 - instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' + instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "latest", "default"]' debian-11: @@ -245,6 +217,20 @@ jobs: instances: '["stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' + debian-13: + name: Debian 13 + if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' + uses: ./.github/workflows/test-linux.yml + needs: + - lint + - generate-actions-workflow + with: + distro-slug: debian-13 + display-name: Debian 13 + timeout: 20 + instances: '["stable-3006", "git-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' + + fedora-40: name: Fedora 40 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' @@ -259,48 +245,6 @@ jobs: instances: '["stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - opensuse-15: - name: Opensuse 15 - if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' - uses: ./.github/workflows/test-linux.yml - needs: - - lint - - generate-actions-workflow - with: - distro-slug: opensuse-15 - display-name: Opensuse 15 - timeout: 20 - instances: '["latest", "default"]' - - - oraclelinux-8: - name: Oracle Linux 8 - if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' - uses: ./.github/workflows/test-linux.yml - needs: - - lint - - generate-actions-workflow - with: - distro-slug: oraclelinux-8 - display-name: Oracle Linux 8 - timeout: 20 - instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "latest", "default"]' - - - oraclelinux-9: - name: Oracle Linux 9 - if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' - uses: ./.github/workflows/test-linux.yml - needs: - - lint - - generate-actions-workflow - with: - distro-slug: oraclelinux-9 - display-name: Oracle Linux 9 - timeout: 20 - instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - - photon-4: name: Photon OS 4 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' @@ -357,7 +301,7 @@ jobs: instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - ubuntu-2004: + ubuntu-20.04: name: Ubuntu 20.04 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' uses: ./.github/workflows/test-linux.yml @@ -365,13 +309,13 @@ jobs: - lint - generate-actions-workflow with: - distro-slug: ubuntu-2004 + distro-slug: ubuntu-20.04 display-name: Ubuntu 20.04 timeout: 20 instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - ubuntu-2204: + ubuntu-22.04: name: Ubuntu 22.04 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' uses: ./.github/workflows/test-linux.yml @@ -379,13 +323,13 @@ jobs: - lint - generate-actions-workflow with: - distro-slug: ubuntu-2204 + distro-slug: ubuntu-22.04 display-name: Ubuntu 22.04 timeout: 20 instances: '["stable-3006", "onedir-3006", "stable-3006-8", "stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' - ubuntu-2404: + ubuntu-24.04: name: Ubuntu 24.04 if: github.event_name == 'push' || needs.collect-changed-files.outputs.run-tests == 'true' uses: ./.github/workflows/test-linux.yml @@ -393,7 +337,7 @@ jobs: - lint - generate-actions-workflow with: - distro-slug: ubuntu-2404 + distro-slug: ubuntu-24.04 display-name: Ubuntu 24.04 timeout: 20 instances: '["stable-3007", "onedir-3007", "stable-3007-1", "git-master", "latest", "default"]' @@ -410,23 +354,19 @@ jobs: - macos-12 - macos-13 - windows-2022 - - almalinux-8 - - almalinux-9 - - amazon-2 - - centos-stream9 + - amazonlinux-2 + - amazonlinux-2023 - debian-11 - debian-12 + - debian-13 - fedora-40 - - opensuse-15 - - oraclelinux-8 - - oraclelinux-9 - photon-4 - photon-5 - rockylinux-8 - rockylinux-9 - - ubuntu-2004 - - ubuntu-2204 - - ubuntu-2404 + - ubuntu-20.04 + - ubuntu-22.04 + - ubuntu-24.04 if: always() steps: diff --git a/.github/workflows/templates/generate.py b/.github/workflows/templates/generate.py index f1a5f39..a9fd62e 100755 --- a/.github/workflows/templates/generate.py +++ b/.github/workflows/templates/generate.py @@ -7,23 +7,19 @@ import pathlib os.chdir(os.path.abspath(os.path.dirname(__file__))) LINUX_DISTROS = [ - "almalinux-8", - "almalinux-9", - "amazon-2", - "centos-stream9", + "amazonlinux-2", + "amazonlinux-2023", "debian-11", "debian-12", + "debian-13", "fedora-40", - "opensuse-15", - "oraclelinux-8", - "oraclelinux-9", "photon-4", "photon-5", "rockylinux-8", "rockylinux-9", - "ubuntu-2004", - "ubuntu-2204", - "ubuntu-2404", + "ubuntu-20.04", + "ubuntu-22.04", + "ubuntu-24.04", ] WINDOWS = [ @@ -36,32 +32,28 @@ OSX = [ ] STABLE_DISTROS = [ - "almalinux-8", - "almalinux-9", - "amazon-2", + "amazonlinux-2", + "amazonlinux-2023", "centos-stream9", "debian-11", "debian-12", + "debian-13", "fedora-40", - "opensuse-15", - "oraclelinux-8", - "oraclelinux-9", "photon-4", "photon-5", "rockylinux-8", "rockylinux-9", - "ubuntu-2004", - "ubuntu-2204", - "ubuntu-2404", + "ubuntu-20.04", + "ubuntu-22.04", + "ubuntu-24.04", ] ONEDIR_DISTROS = [ - "almalinux-8", - "almalinux-9", - "amazon-2", - "centos-stream9", + "amazonlinux-2", + "amazonlinux-2023", "debian-11", "debian-12", + "debian-13", "fedora-40", "oraclelinux-8", "oraclelinux-9", @@ -69,72 +61,64 @@ ONEDIR_DISTROS = [ "photon-5", "rockylinux-8", "rockylinux-9", - "ubuntu-2004", - "ubuntu-2204", - "ubuntu-2404", + "ubuntu-20.04", + "ubuntu-22.04", + "ubuntu-24.04", ] ONEDIR_RC_DISTROS = [ - "almalinux-9", - "amazon-2", - "centos-stream9", + "amazonlinux-2", + "amazonlinux-2023", "debian-12", - "oraclelinux-9", "photon-4", "photon-5", "rockylinux-9", - "ubuntu-2404", + "ubuntu-24.04", ] BLACKLIST_3006 = [ "debian-12", "fedora-40", - "opensuse-15", - "ubuntu-2404", + "ubuntu-24.04", ] BLACKLIST_3007 = [ - "opensuse-15", "photon-4", "photon-5", ] BLACKLIST_GIT_3006 = [ - "almalinux-9", - "amazon-2", - "centos-stream9", + "amazonlinux-2", + "amazonlinux-2023", "debian-11", "debian-12", "fedora-40", - "opensuse-15", - "oraclelinux-9", "photon-4", "photon-5", "rockylinux-9", - "ubuntu-2004", - "ubuntu-2204", - "ubuntu-2404", + "ubuntu-20.04", + "ubuntu-22.04", + "ubuntu-24.04", ] BLACKLIST_GIT_3007 = [ - "almalinux-9", - "amazon-2", - "centos-stream9", + "amazonlinux-2", + "amazonlinux-2023", "debian-11", "debian-12", + "debian-13", "fedora-40", - "opensuse-15", - "oraclelinux-9", "photon-4", "photon-5", "rockylinux-9", - "ubuntu-2004", - "ubuntu-2204", - "ubuntu-2404", + "ubuntu-20.04", + "ubuntu-22.04", + "ubuntu-24.04", ] BLACKLIST_GIT_MASTER = [ - "amazon-2", + "amazonlinux-2", + "amazonlinux-2023", "photon-4", "photon-5", ] @@ -193,32 +177,25 @@ GIT_VERSION_BLACKLIST = [ # Use build and pip and other standards-based tools. # GIT_DISTRO_BLACKLIST = [ - "almalinux-8", - "opensuse-15", - "oraclelinux-8", "rockylinux-8", ] LATEST_PKG_BLACKLIST = [] DISTRO_DISPLAY_NAMES = { - "almalinux-8": "AlmaLinux 8", - "almalinux-9": "AlmaLinux 9", - "amazon-2": "Amazon 2", - "centos-stream9": "CentOS Stream 9", + "amazonlinux-2": "Amazon 2", + "amazonlinux-2023": "Amazon 2023", "debian-11": "Debian 11", "debian-12": "Debian 12", + "debian-13": "Debian 13", "fedora-40": "Fedora 40", - "opensuse-15": "Opensuse 15", - "oraclelinux-8": "Oracle Linux 8", - "oraclelinux-9": "Oracle Linux 9", "photon-4": "Photon OS 4", "photon-5": "Photon OS 5", "rockylinux-8": "Rocky Linux 8", "rockylinux-9": "Rocky Linux 9", - "ubuntu-2004": "Ubuntu 20.04", - "ubuntu-2204": "Ubuntu 22.04", - "ubuntu-2404": "Ubuntu 24.04", + "ubuntu-20.04": "Ubuntu 20.04", + "ubuntu-22.04": "Ubuntu 22.04", + "ubuntu-24.04": "Ubuntu 24.04", "macos-12": "macOS 12", "macos-13": "macOS 13", "windows-2022": "Windows 2022", diff --git a/.github/workflows/test-linux.yml b/.github/workflows/test-linux.yml index 8a2eda0..80b2e09 100644 --- a/.github/workflows/test-linux.yml +++ b/.github/workflows/test-linux.yml @@ -28,9 +28,7 @@ jobs: name: ${{ matrix.instance }} runs-on: ubuntu-latest container: - $trgt_version = echo "${{ inputs.display-name }}" | awk -F ' ' '{print $2}' - $trgt_slug = echo "${{ inputs.distro-slug}}" | awk -F '-' '{print $1}' - image: ghcr.io/saltstack/salt-ci-containers/testing:${{ trgt_slug }}-${{ trgt_version }} + image: ghcr.io/saltstack/salt-ci-containers/testing:${{ inputs.distro-slug}} timeout-minutes: ${{ inputs.timeout }} strategy: diff --git a/bootstrap-salt.sh b/bootstrap-salt.sh index d4fa965..6b81597 100755 --- a/bootstrap-salt.sh +++ b/bootstrap-salt.sh @@ -4993,79 +4993,79 @@ install_oracle_linux_check_services() { ####################################################################################################################### # -# AlmaLinux Install Functions +# RockyLinux Install Functions # -install_almalinux_stable_deps() { +install_rockylinux_stable_deps() { install_centos_stable_deps || return 1 return 0 } -install_almalinux_git_deps() { +install_rockylinux_git_deps() { install_centos_git_deps || return 1 return 0 } -install_almalinux_onedir_deps() { +install_rockylinux_onedir_deps() { install_centos_onedir_deps || return 1 return 0 } -install_almalinux_testing_deps() { +install_rockylinux_testing_deps() { install_centos_testing_deps || return 1 return 0 } -install_almalinux_stable() { +install_rockylinux_stable() { install_centos_stable || return 1 return 0 } -install_almalinux_git() { +install_rockylinux_git() { install_centos_git || return 1 return 0 } -install_almalinux_onedir() { +install_rockylinux_onedir() { install_centos_onedir || return 1 return 0 } -install_almalinux_testing() { +install_rockylinux_testing() { install_centos_testing || return 1 return 0 } -install_almalinux_stable_post() { +install_rockylinux_stable_post() { install_centos_stable_post || return 1 return 0 } -install_almalinux_git_post() { +install_rockylinux_git_post() { install_centos_git_post || return 1 return 0 } -install_almalinux_onedir_post() { +install_rockylinux_onedir_post() { install_centos_onedir_post || return 1 return 0 } -install_almalinux_testing_post() { +install_rockylinux_testing_post() { install_centos_testing_post || return 1 return 0 } -install_almalinux_restart_daemons() { +install_rockylinux_restart_daemons() { install_centos_restart_daemons || return 1 return 0 } -install_almalinux_check_services() { +install_rockylinux_check_services() { install_centos_check_services || return 1 return 0 } # -# Ended AlmaLinux Install Functions +# Ended RockyLinux Install Functions # #######################################################################################################################