From 85f4047e2b78ba84d6a4bbc1aaa2ba37952cdb8a Mon Sep 17 00:00:00 2001 From: Travis Nielsen Date: Fri, 12 Dec 2025 13:53:27 -0700 Subject: [PATCH] ci: test rook upgrade from 1.18 The upgrade test is expected to check from the previous minor release to the current master or latest release. With the release of 1.19 coming soon, the upgrade test will now check from v1.18.x. Signed-off-by: Travis Nielsen (cherry picked from commit 94e9e2ba91819e58701649873088b579db645a7d) --- tests/framework/installer/ceph_installer.go | 5 ----- tests/framework/installer/ceph_manifests.go | 2 +- tests/framework/installer/ceph_manifests_previous.go | 5 +++-- tests/integration/ceph_upgrade_test.go | 6 ++---- 4 files changed, 6 insertions(+), 12 deletions(-) diff --git a/tests/framework/installer/ceph_installer.go b/tests/framework/installer/ceph_installer.go index f00c52e02..95416fd53 100644 --- a/tests/framework/installer/ceph_installer.go +++ b/tests/framework/installer/ceph_installer.go @@ -468,11 +468,6 @@ func (h *CephInstaller) GetNodeHostnames() ([]string, error) { } func (h *CephInstaller) InstallCSIOperator() error { - if h.settings.RookVersion == Version1_17 { - logger.Infof("Skipping the CSI operator installation for previous version of Rook") - return nil - } - logger.Infof("Starting the CSI operator") _, err := h.k8shelper.KubectlWithStdin(h.Manifests.GetCSIOperator(), createFromStdinArgs...) if err != nil { diff --git a/tests/framework/installer/ceph_manifests.go b/tests/framework/installer/ceph_manifests.go index 04b71914a..8266d4da7 100644 --- a/tests/framework/installer/ceph_manifests.go +++ b/tests/framework/installer/ceph_manifests.go @@ -72,7 +72,7 @@ func NewCephManifests(settings *TestCephSettings) CephManifests { switch settings.RookVersion { case LocalBuildTag: return &CephManifestsMaster{settings} - case Version1_17: + case Version1_18: return &CephManifestsPreviousVersion{settings, &CephManifestsMaster{settings}} } panic(fmt.Errorf("unrecognized ceph manifest version: %s", settings.RookVersion)) diff --git a/tests/framework/installer/ceph_manifests_previous.go b/tests/framework/installer/ceph_manifests_previous.go index a2c247326..2cfa5f4f7 100644 --- a/tests/framework/installer/ceph_manifests_previous.go +++ b/tests/framework/installer/ceph_manifests_previous.go @@ -24,7 +24,7 @@ import ( const ( // The version from which the upgrade test will start - Version1_17 = "v1.17.7" + Version1_18 = "v1.18.8" ) // CephManifestsPreviousVersion wraps rook yaml definitions @@ -46,7 +46,8 @@ func (m *CephManifestsPreviousVersion) GetCSINFSRBAC() string { } func (m *CephManifestsPreviousVersion) GetCSIOperator() string { - return "not-supported" + manifest := m.settings.readManifestFromGitHub("csi-operator.yaml") + return m.settings.replaceCSIOperatorSettings(m.settings.OperatorNamespace, manifest) } // GetRookOperator returns rook Operator manifest diff --git a/tests/integration/ceph_upgrade_test.go b/tests/integration/ceph_upgrade_test.go index 6d66bb766..7fccac587 100644 --- a/tests/integration/ceph_upgrade_test.go +++ b/tests/integration/ceph_upgrade_test.go @@ -106,7 +106,7 @@ func (s *UpgradeSuite) TestUpgradeHelm() { } func (s *UpgradeSuite) testUpgrade(useHelm bool, initialCephVersion v1.CephVersionSpec) { - baseRookImage := installer.Version1_17 + baseRookImage := installer.Version1_18 s.baseSetup(useHelm, baseRookImage, initialCephVersion) objectUserID := "upgraded-user" @@ -454,9 +454,7 @@ func (s *UpgradeSuite) upgradeToMaster() { return } - require.NoError(s.T(), s.installer.InstallCSIOperator()) - require.NoError(s.T(), s.installer.SetOperatorSetting("ROOK_USE_CSI_OPERATOR", "true")) - + require.NoError(s.T(), s.k8sh.ResourceOperation("apply", s.installer.Manifests.GetCSIOperator())) require.NoError(s.T(), s.k8sh.ResourceOperation("apply", s.installer.Manifests.GetCRDs(s.k8sh))) require.NoError(s.T(), s.k8sh.ResourceOperation("apply", s.installer.Manifests.GetCommon()))