Upgrade a Hardened Custom/Imported Cluster to Kubernetes v1.25
If you have custom or imported hardened clusters, you must take special preparations to ensure that the upgrade from an earlier version of Kubernetes to v1.25 or later goes smoothly.
备注
- RKE2
- K3s
Perform the following on each node in the cluster:
- Save in .
- Edit the RKE2 configuration file:
- Update the
profile
field tocis-1.23
. - Specify the path for the configuration file that you just added: .
- Update the
Perform the following on each node in the cluster:
After you perform these steps, you can upgrade the cluster’s Kubernetes version through the Rancher UI:
- In the upper left corner, click ☰ > Cluster Management.
- Select Edit Config.
- In the Kubernetes Version dropdown menu, select the version that you would like to use.
- Click Save.
Upgrading Custom Hardened Clusters to Kubernetes v1.25 or Later
- RKE2
- K3s
- In the upper left corner, click ☰ > Cluster Management.
- Find the cluster you want to update in the Clusters table, and click the ⋮.
- Select Edit Config.
- Under Basics > Security, in the CIS Profile dropdown menu, select
cis-1.23
. - In the Kubernetes Version dropdown menu, select the version that you would like to use.
Click Save.
- Find the cluster you want to update in the Clusters table, and click the ⋮.
- Select Edit YAML.
- Delete from
kube-apiserver-arg.enable-admission-plugins
- Add this line to the
spec
field: - Update
kubernetesVersion
to your chosen version (v1.25 or later). - Click Save.