utils: align regex of parse_ceph_version with Perl equivalent

Signed-off-by: Max Carrara <m.carrara@proxmox.com>
Tested-by: Lukas Wagner <l.wagner@proxmox.com>
Reviewed-by: Lukas Wagner <l.wagner@proxmox.com>
Tested-by: Igor Thaller <igor.thaller@brg9.at>
This commit is contained in:
Max Carrara 2024-07-01 16:10:35 +02:00 committed by Thomas Lamprecht
parent ddf6263191
commit 48b64ef35b

View File

@ -118,7 +118,8 @@ Ext.define('PVE.Utils', {
} }
if (service.ceph_version) { if (service.ceph_version) {
var match = service.ceph_version.match(/version (\d+(\.\d+)*)/); // See PVE/Ceph/Tools.pm - get_local_version
const match = service.ceph_version.match(/^ceph.*\sv?(\d+(?:\.\d+)+)/);
if (match) { if (match) {
return match[1]; return match[1];
} }