From 7271e6f67d1356f980bd8626881f1053d698c72c Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Tue, 21 Jun 2022 17:04:21 +0200 Subject: [PATCH] pveceph: reuse supported ceph versions for non-default warning albeit this is a bit odd safety "check" anyway Signed-off-by: Thomas Lamprecht --- PVE/CLI/pveceph.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PVE/CLI/pveceph.pm b/PVE/CLI/pveceph.pm index 62763ad2..41005bcf 100755 --- a/PVE/CLI/pveceph.pm +++ b/PVE/CLI/pveceph.pm @@ -159,8 +159,8 @@ __PACKAGE__->register_method ({ } PVE::Tools::file_set_contents("/etc/apt/sources.list.d/ceph.list", $repolist); - warn "WARNING: installing non-default ceph release '$cephver'!\n" - if $cephver !~ qr/^(?:octopus|pacific)$/; + my $supported_re = join('|', $supported_ceph_versions->@*); + warn "WARNING: installing non-default ceph release '$cephver'!\n" if $cephver !~ qr/^(?:$supported_re)$/; local $ENV{DEBIAN_FRONTEND} = 'noninteractive'; print "update available package list\n";