my $rw = 0;
$rw = 1 if $output eq "fish";
my $g;
+my @images;
if ($uri) {
- $g = open_guest (\@ARGV, rw => $rw, address => $uri);
+ my ($conn, $dom);
+ ($g, $conn, $dom, @images) =
+ open_guest (\@ARGV, rw => $rw, address => $uri);
} else {
- $g = open_guest (\@ARGV, rw => $rw);
+ my ($conn, $dom);
+ ($g, $conn, $dom, @images) =
+ open_guest (\@ARGV, rw => $rw);
}
$g->launch ();
print "--ro ";
}
- print "-a $_ " foreach @ARGV;
+ print "-a $_ " foreach @images;
my $mounts = $oses->{$root_dev}->{mounts};
# Have to mount / first. Luckily '/' is early in the ASCII
foreach ( [ "name" => "os" ],
[ "distro" => "distro" ],
[ "version" => "version" ],
+ [ "package_format" => "package_format" ],
+ [ "package_management" => "package_management" ],
[ "root" => "root_device" ] ) {
$xml->dataElement($_->[0], $os->{$_->[1]}) if exists $os->{$_->[1]};
}
{
my $rhel = "no";
foreach my $os (keys %$oses) {
- $rhel="yes" if $oses->{$os}->{os} eq "linux" && $oses->{$os}->{distro} eq "redhat";
+ $rhel="yes" if ($oses->{$os}->{os} eq "linux" &&
+ $oses->{$os}->{distro} eq "rhel");
}
print "rhel=$rhel\n";
}