[pve-devel] [PATCH manager] report: fix regex of config filenames

Alexander Zeidler a.zeidler at proxmox.com
Thu Apr 18 09:44:04 CEST 2024


to only match those that are correct/accepted by their software

Signed-off-by: Alexander Zeidler <a.zeidler at proxmox.com>
---
 PVE/Report.pm | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/PVE/Report.pm b/PVE/Report.pm
index 9c46aa9b..53ffdcbb 100644
--- a/PVE/Report.pm
+++ b/PVE/Report.pm
@@ -35,8 +35,8 @@ my $init_report_cmds = sub {
 		'cat /etc/hosts',
 		'pvesubscription get',
 		'cat /etc/apt/sources.list',
-		sub { dir2text('/etc/apt/sources.list.d/', '.*list') },
-		sub { dir2text('/etc/apt/sources.list.d/', '.*sources') },
+		sub { dir2text('/etc/apt/sources.list.d/', '.+\.list') },
+		sub { dir2text('/etc/apt/sources.list.d/', '.+\.sources') },
 		'lscpu',
 		'pvesh get /cluster/resources --type node --output-format=yaml',
 	    ],
@@ -64,9 +64,9 @@ my $init_report_cmds = sub {
 	    order => 40,
 	    cmds => [
 		'qm list',
-		sub { dir2text('/etc/pve/qemu-server/', '\d.*conf') },
+		sub { dir2text('/etc/pve/qemu-server/', '\d+\.conf') },
 		'pct list',
-		sub { dir2text('/etc/pve/lxc/', '\d.*conf') },
+		sub { dir2text('/etc/pve/lxc/', '\d+\.conf') },
 	    ],
 	},
 	network => {
@@ -83,7 +83,7 @@ my $init_report_cmds = sub {
 	firewall => {
 	    order => 50,
 	    cmds => [
-		sub { dir2text('/etc/pve/firewall/', '.*fw') },
+		sub { dir2text('/etc/pve/firewall/', '.+\.fw') },
 		'cat /etc/pve/local/host.fw',
 		'iptables-save -c | column -t -l4 -o" "',
 	    ],
-- 
2.39.2





More information about the pve-devel mailing list