mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Programmatically discover which OS versions to build repos
Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
This commit is contained in:
parent
a51d3e00dd
commit
f1ed56c2a5
3 changed files with 121 additions and 110 deletions
92
.github/workflows/nightly.yml
vendored
92
.github/workflows/nightly.yml
vendored
|
@ -2239,6 +2239,14 @@ jobs:
|
|||
distro: ubuntu
|
||||
version: "22.04"
|
||||
arch: arm64
|
||||
- pkg-type: deb
|
||||
distro: ubuntu
|
||||
version: "23.04"
|
||||
arch: x86_64
|
||||
- pkg-type: deb
|
||||
distro: ubuntu
|
||||
version: "23.04"
|
||||
arch: arm64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
@ -2352,54 +2360,6 @@ jobs:
|
|||
distro: amazon
|
||||
version: "2023"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "37"
|
||||
|
@ -2460,6 +2420,42 @@ jobs:
|
|||
distro: photon
|
||||
version: "5"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: aarch64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
|
92
.github/workflows/staging.yml
vendored
92
.github/workflows/staging.yml
vendored
|
@ -2082,6 +2082,14 @@ jobs:
|
|||
distro: ubuntu
|
||||
version: "22.04"
|
||||
arch: arm64
|
||||
- pkg-type: deb
|
||||
distro: ubuntu
|
||||
version: "23.04"
|
||||
arch: x86_64
|
||||
- pkg-type: deb
|
||||
distro: ubuntu
|
||||
version: "23.04"
|
||||
arch: arm64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
@ -2195,54 +2203,6 @@ jobs:
|
|||
distro: amazon
|
||||
version: "2023"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "36"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: fedora
|
||||
version: "37"
|
||||
|
@ -2303,6 +2263,42 @@ jobs:
|
|||
distro: photon
|
||||
version: "5"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "7"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "8"
|
||||
arch: aarch64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: x86_64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: arm64
|
||||
- pkg-type: rpm
|
||||
distro: redhat
|
||||
version: "9"
|
||||
arch: aarch64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
|
|
@ -253,24 +253,43 @@ def generate_workflows(ctx: Context):
|
|||
test_salt_pkg_downloads_needs_slugs.add("build-ci-deps")
|
||||
|
||||
build_rpms_listing = []
|
||||
for distro, releases in (
|
||||
("amazon", ("2", "2023")),
|
||||
("redhat", ("7", "8", "9")),
|
||||
("fedora", ("36", "37", "38")),
|
||||
("photon", ("3", "4", "5")),
|
||||
):
|
||||
for release in releases:
|
||||
rpm_os_versions: dict[str, list[str]] = {
|
||||
"amazon": [],
|
||||
"fedora": [],
|
||||
"photon": [],
|
||||
"redhat": [],
|
||||
}
|
||||
for slug in sorted(AMIS):
|
||||
if slug.endswith("-arm64"):
|
||||
continue
|
||||
if not slug.startswith(
|
||||
("amazonlinux", "almalinux", "centos", "fedora", "photonos")
|
||||
):
|
||||
continue
|
||||
os_name, os_version = slug.split("-")
|
||||
if os_name == "amazonlinux":
|
||||
rpm_os_versions["amazon"].append(os_version)
|
||||
elif os_name == "photonos":
|
||||
rpm_os_versions["photon"].append(os_version)
|
||||
elif os_name == "fedora":
|
||||
rpm_os_versions["fedora"].append(os_version)
|
||||
else:
|
||||
rpm_os_versions["redhat"].append(os_version)
|
||||
|
||||
for distro, releases in sorted(rpm_os_versions.items()):
|
||||
for release in sorted(set(releases)):
|
||||
for arch in ("x86_64", "arm64", "aarch64"):
|
||||
build_rpms_listing.append((distro, release, arch))
|
||||
|
||||
build_debs_listing = []
|
||||
for distro, releases in (
|
||||
("debian", ("10", "11", "12")),
|
||||
("ubuntu", ("20.04", "22.04")),
|
||||
):
|
||||
for release in releases:
|
||||
for arch in ("x86_64", "arm64"):
|
||||
build_debs_listing.append((distro, release, arch))
|
||||
for slug in sorted(AMIS):
|
||||
if not slug.startswith(("debian-", "ubuntu-")):
|
||||
continue
|
||||
if slug.endswith("-arm64"):
|
||||
continue
|
||||
os_name, os_version = slug.split("-")
|
||||
for arch in ("x86_64", "arm64"):
|
||||
build_debs_listing.append((os_name, os_version, arch))
|
||||
|
||||
env = Environment(
|
||||
block_start_string="<%",
|
||||
|
|
Loading…
Add table
Reference in a new issue