tests: multi cluster suite toolbox version
The toolbox image tag was always being set from #12625 even when the image was not set in the test. If the image is not set, skip replacing the image name to use the default test version. Signed-off-by: travisn <tnielsen@redhat.com>
This commit is contained in:
1 file changed
+6
-4
@@ -114,10 +114,12 @@ func (m *CephManifestsMaster) GetToolbox() string {
|
||||
return strings.ReplaceAll(manifest, "app: rook-direct-mount", "app: rook-ceph-tools")
|
||||
}
|
||||
manifest := m.settings.readManifest("toolbox.yaml")
|
||||
// The toolbox uses the ceph image, so replace the version that is being tested
|
||||
// The regex allows for any character in the tag ("\S" --> non-whitespace character)
|
||||
versionRegex := regexp.MustCompile(`image: quay.io/ceph/ceph:\S+`)
|
||||
manifest = versionRegex.ReplaceAllString(manifest, "image: "+m.settings.CephVersion.Image)
|
||||
if m.settings.CephVersion.Image != "" {
|
||||
// The toolbox uses the ceph image, so replace the version that is being tested
|
||||
// The regex allows for any character in the tag ("\S" --> non-whitespace character)
|
||||
versionRegex := regexp.MustCompile(`image: quay.io/ceph/ceph:\S+`)
|
||||
manifest = versionRegex.ReplaceAllString(manifest, "image: "+m.settings.CephVersion.Image)
|
||||
}
|
||||
return manifest
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user