mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-10-21 23:28:19 +00:00
d95b190461
xCAT builds and runs on aarch64, but two pieces were missing for an EL10
aarch64 management node:
- No compute.rhels10.aarch64.{pkglist,exlist,postinstall}, so genimage
fell back to the generic EL8/9-shaped compute.pkglist (dhclient,
busybox-anaconda), which does not resolve on EL10 aarch64. Add the rh
files (same content as the other EL10 architectures) with alma/rocky
aliases, following the x86_64/ppc64le layout.
- xCAT.spec had Requires blocks for x86, ppc and riscv64 but none for
aarch64, so an aarch64 install pulled no ipmitool-xcat. Add the block,
mirroring riscv64: ipmitool-xcat plus ipxe-xcat (an aarch64 management
node can serve x86 nodes); the x86-only PXE stack stays excluded.
Tests: extend el10_netboot_dhcp_client.t to the aarch64 lists and add
aarch64_packaging.t for the spec block and the netboot file layout.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Timothy Middelkoop <tmiddelkoop@internet2.edu>
55 lines
2.1 KiB
Perl
55 lines
2.1 KiB
Perl
#!/usr/bin/env perl
|
|
use strict;
|
|
use warnings;
|
|
|
|
use FindBin;
|
|
use lib "$FindBin::Bin/../lib";
|
|
use Test::More;
|
|
|
|
use XCAT::Test::File qw(repo_path slurp_repo_file);
|
|
|
|
my $spec = slurp_repo_file('xCAT-server/xCAT-server.spec');
|
|
unlike( $spec, qr/\bdnf\s+download\b/, 'xCAT-server RPM scripts do not download packages' );
|
|
unlike( $spec, qr{/install/dhcp_pkgs}, 'xCAT-server RPM scripts do not write hidden DHCP package directories' );
|
|
|
|
my $anaconda = slurp_repo_file('xCAT-server/lib/xcat/plugins/anaconda.pm');
|
|
unlike( $anaconda, qr{/install/dhcp_pkgs}, 'copycds does not inject hidden DHCP package directories into pkgdir' );
|
|
|
|
my @pkglist_files = qw(
|
|
xCAT-server/share/xcat/netboot/rh/compute.rhels10.aarch64.pkglist
|
|
xCAT-server/share/xcat/netboot/rh/compute.rhels10.ppc64le.pkglist
|
|
xCAT-server/share/xcat/netboot/rh/compute.rhels10.x86_64.pkglist
|
|
);
|
|
|
|
my %el10_pkglist_aliases = (
|
|
'xCAT-server/share/xcat/netboot/alma/compute.alma10.aarch64.pkglist' => '../rh/compute.rhels10.aarch64.pkglist',
|
|
'xCAT-server/share/xcat/netboot/rocky/compute.rocky10.aarch64.pkglist' => '../rh/compute.rhels10.aarch64.pkglist',
|
|
'xCAT-server/share/xcat/netboot/rocky/compute.rocky10.ppc64le.pkglist' => '../rh/compute.rhels10.ppc64le.pkglist',
|
|
'xCAT-server/share/xcat/netboot/rocky/compute.rocky10.x86_64.pkglist' => '../rh/compute.rhels10.x86_64.pkglist',
|
|
);
|
|
|
|
foreach my $file ( sort keys %el10_pkglist_aliases ) {
|
|
my $path = repo_path($file);
|
|
is( readlink($path), $el10_pkglist_aliases{$file}, "$file uses the EL10 package list" );
|
|
}
|
|
|
|
foreach my $file (@pkglist_files) {
|
|
my $path = repo_path($file);
|
|
open( my $fh, '<', $path ) or die "Unable to read $path: $!";
|
|
|
|
my @packages;
|
|
while ( my $line = <$fh> ) {
|
|
chomp $line;
|
|
next if $line =~ /^\s*(?:#|$)/;
|
|
push @packages, $line;
|
|
}
|
|
close($fh);
|
|
|
|
my %packages = map { $_ => 1 } @packages;
|
|
ok( $packages{'NetworkManager'}, "$file uses NetworkManager for EL10 DHCP handling" );
|
|
ok( !$packages{'dhclient'}, "$file avoids removed dhclient package" );
|
|
ok( !$packages{'dhcp-client'}, "$file avoids removed dhcp-client package" );
|
|
}
|
|
|
|
done_testing();
|