mirror of
git://git.proxmox.com/git/qemu-server.git
synced 2025-03-30 06:50:14 +03:00
cloudinit: use normal grep
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
50bbe37787
commit
6ef6d68f6c
@ -171,7 +171,7 @@ sub configdrive2_network {
|
||||
$content .= " dns_search $searchdomains\n";
|
||||
}
|
||||
|
||||
my @ifaces = grep(/^net(\d+)$/, keys %$conf);
|
||||
my @ifaces = grep { /^net(\d+)$/ } keys %$conf;
|
||||
foreach my $iface (sort @ifaces) {
|
||||
(my $id = $iface) =~ s/^net//;
|
||||
next if !$conf->{"ipconfig$id"};
|
||||
@ -251,7 +251,7 @@ sub nocloud_network_v2 {
|
||||
|
||||
my $dns_done;
|
||||
|
||||
my @ifaces = grep(/^net(\d+)$/, keys %$conf);
|
||||
my @ifaces = grep { /^net(\d+)$/ } keys %$conf;
|
||||
foreach my $iface (sort @ifaces) {
|
||||
(my $id = $iface) =~ s/^net//;
|
||||
next if !$conf->{"ipconfig$id"};
|
||||
@ -322,7 +322,7 @@ sub nocloud_network {
|
||||
my $content = "version: 1\n"
|
||||
. "config:\n";
|
||||
|
||||
my @ifaces = grep(/^net(\d+)$/, keys %$conf);
|
||||
my @ifaces = grep { /^net(\d+)$/ } keys %$conf;
|
||||
foreach my $iface (sort @ifaces) {
|
||||
(my $id = $iface) =~ s/^net//;
|
||||
next if !$conf->{"ipconfig$id"};
|
||||
|
Loading…
x
Reference in New Issue
Block a user