mirror of https://github.com/kubernetes/kops.git
Add support for Rocky 9
This commit is contained in:
parent
797dc11451
commit
e5244af31a
|
@ -49,6 +49,7 @@ The following table provides the support status for various distros with regards
|
||||||
| [RHEL 8](#rhel-8) | 1.15 | 1.18 | - | - |
|
| [RHEL 8](#rhel-8) | 1.15 | 1.18 | - | - |
|
||||||
| [RHEL 9](#rhel-9) | 1.27 | - | - | - |
|
| [RHEL 9](#rhel-9) | 1.27 | - | - | - |
|
||||||
| [Rocky 8](#rocky-8) | 1.23.2 | 1.24 | - | - |
|
| [Rocky 8](#rocky-8) | 1.23.2 | 1.24 | - | - |
|
||||||
|
| [Rocky 9](#rocky-9) | 1.30 | - | - | - |
|
||||||
| Ubuntu 16.04 | 1.5 | 1.10 | 1.17 | 1.20 |
|
| Ubuntu 16.04 | 1.5 | 1.10 | 1.17 | 1.20 |
|
||||||
| Ubuntu 18.04 | 1.10 | 1.16 | 1.26 | 1.28 |
|
| Ubuntu 18.04 | 1.10 | 1.16 | 1.26 | 1.28 |
|
||||||
| [Ubuntu 20.04](#ubuntu-2004-focal) | 1.16.2 | 1.18 | - | - |
|
| [Ubuntu 20.04](#ubuntu-2004-focal) | 1.16.2 | 1.18 | - | - |
|
||||||
|
@ -209,6 +210,20 @@ aws ec2 describe-images --region us-east-1 --output table \
|
||||||
--filters "Name=name,Values=Rocky-8-ec2-8.*.*"
|
--filters "Name=name,Values=Rocky-8-ec2-8.*.*"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Rocky 9
|
||||||
|
|
||||||
|
Rocky Linux 9 is based on Kernel version **5.14**.
|
||||||
|
|
||||||
|
Available images can be listed using:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
aws ec2 describe-images --region us-east-1 --output table \
|
||||||
|
--owners 792107900819 \
|
||||||
|
--query "sort_by(Images, &CreationDate)[*].[CreationDate,Name,ImageId]" \
|
||||||
|
--filters "Name=name,Values=Rocky-9-EC2-Base-9.*.*"
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
### Ubuntu 20.04 (Focal)
|
### Ubuntu 20.04 (Focal)
|
||||||
|
|
||||||
Ubuntu 20.04 is based on Kernel version **5.4** which fixes all the known major Kernel bugs.
|
Ubuntu 20.04 is based on Kernel version **5.4** which fixes all the known major Kernel bugs.
|
||||||
|
|
|
@ -22,6 +22,7 @@ import (
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"path"
|
"path"
|
||||||
"reflect"
|
"reflect"
|
||||||
|
"slices"
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
|
@ -326,7 +327,11 @@ func (_ *Package) RenderLocal(t *local.LocalTarget, a, e, changes *Package) erro
|
||||||
args = []string{"apt-get", "install", "--yes", "--no-install-recommends"}
|
args = []string{"apt-get", "install", "--yes", "--no-install-recommends"}
|
||||||
env = append(env, "DEBIAN_FRONTEND=noninteractive")
|
env = append(env, "DEBIAN_FRONTEND=noninteractive")
|
||||||
} else if d.IsRHELFamily() {
|
} else if d.IsRHELFamily() {
|
||||||
if d == distributions.DistributionRhel8 || d == distributions.DistributionRocky8 || d == distributions.DistributionRhel9 {
|
|
||||||
|
if slices.Contains([]distributions.Distribution{
|
||||||
|
distributions.DistributionRhel8, distributions.DistributionRocky8,
|
||||||
|
distributions.DistributionRhel9, distributions.DistributionRocky9,
|
||||||
|
}, d) {
|
||||||
args = []string{"/usr/bin/dnf", "install", "-y", "--setopt=install_weak_deps=False"}
|
args = []string{"/usr/bin/dnf", "install", "-y", "--setopt=install_weak_deps=False"}
|
||||||
} else {
|
} else {
|
||||||
args = []string{"/usr/bin/yum", "install", "-y"}
|
args = []string{"/usr/bin/yum", "install", "-y"}
|
||||||
|
|
|
@ -49,6 +49,7 @@ var (
|
||||||
DistributionRhel8 = Distribution{packageFormat: "rpm", project: "rhel", id: "rhel8", version: 8}
|
DistributionRhel8 = Distribution{packageFormat: "rpm", project: "rhel", id: "rhel8", version: 8}
|
||||||
DistributionRhel9 = Distribution{packageFormat: "rpm", project: "rhel", id: "rhel9", version: 9}
|
DistributionRhel9 = Distribution{packageFormat: "rpm", project: "rhel", id: "rhel9", version: 9}
|
||||||
DistributionRocky8 = Distribution{packageFormat: "rpm", project: "rocky", id: "rocky8", version: 8}
|
DistributionRocky8 = Distribution{packageFormat: "rpm", project: "rocky", id: "rocky8", version: 8}
|
||||||
|
DistributionRocky9 = Distribution{packageFormat: "rpm", project: "rocky", id: "rocky9", version: 9}
|
||||||
DistributionFlatcar = Distribution{packageFormat: "", project: "flatcar", id: "flatcar", version: 0}
|
DistributionFlatcar = Distribution{packageFormat: "", project: "flatcar", id: "flatcar", version: 0}
|
||||||
DistributionContainerOS = Distribution{packageFormat: "", project: "containeros", id: "containeros", version: 0}
|
DistributionContainerOS = Distribution{packageFormat: "", project: "containeros", id: "containeros", version: 0}
|
||||||
)
|
)
|
||||||
|
|
|
@ -82,6 +82,9 @@ func FindDistribution(rootfs string) (Distribution, error) {
|
||||||
if strings.HasPrefix(distro, "rocky-8.") {
|
if strings.HasPrefix(distro, "rocky-8.") {
|
||||||
return DistributionRocky8, nil
|
return DistributionRocky8, nil
|
||||||
}
|
}
|
||||||
|
if strings.HasPrefix(distro, "rocky-9.") {
|
||||||
|
return DistributionRocky9, nil
|
||||||
|
}
|
||||||
|
|
||||||
// Some distros are not supported
|
// Some distros are not supported
|
||||||
klog.V(2).Infof("Contents of /etc/os-release:\n%s", osReleaseBytes)
|
klog.V(2).Infof("Contents of /etc/os-release:\n%s", osReleaseBytes)
|
||||||
|
|
|
@ -109,6 +109,11 @@ func TestFindDistribution(t *testing.T) {
|
||||||
err: nil,
|
err: nil,
|
||||||
expected: DistributionRocky8,
|
expected: DistributionRocky8,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
rootfs: "rocky9",
|
||||||
|
err: nil,
|
||||||
|
expected: DistributionRocky9,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
rootfs: "ubuntu1604",
|
rootfs: "ubuntu1604",
|
||||||
err: fmt.Errorf("unsupported distro: ubuntu-16.04"),
|
err: fmt.Errorf("unsupported distro: ubuntu-16.04"),
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
NAME="Rocky Linux"
|
||||||
|
VERSION="9.4 (Blue Onyx)"
|
||||||
|
ID="rocky"
|
||||||
|
ID_LIKE="rhel centos fedora"
|
||||||
|
VERSION_ID="9.4"
|
||||||
|
PLATFORM_ID="platform:el9"
|
||||||
|
PRETTY_NAME="Rocky Linux 9.4 (Blue Onyx)"
|
||||||
|
ANSI_COLOR="0;32"
|
||||||
|
LOGO="fedora-logo-icon"
|
||||||
|
CPE_NAME="cpe:/o:rocky:rocky:9::baseos"
|
||||||
|
HOME_URL="https://rockylinux.org/"
|
||||||
|
BUG_REPORT_URL="https://bugs.rockylinux.org/"
|
||||||
|
SUPPORT_END="2032-05-31"
|
||||||
|
ROCKY_SUPPORT_PRODUCT="Rocky-Linux-9"
|
||||||
|
ROCKY_SUPPORT_PRODUCT_VERSION="9.4"
|
||||||
|
REDHAT_SUPPORT_PRODUCT="Rocky Linux"
|
||||||
|
REDHAT_SUPPORT_PRODUCT_VERSION="9.4"
|
Loading…
Reference in New Issue