Skip to content

Commit 711aab6

Browse files
committed
containerd: add cross compilation tests
1 parent 3f48f68 commit 711aab6

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

pkgs/by-name/co/containerd/package.nix

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
lib,
33
stdenv,
4+
pkgsCross,
45
btrfs-progs,
56
buildGoModule,
67
fetchFromGitHub,
@@ -69,9 +70,18 @@ buildGoModule rec {
6970
'';
7071

7172
passthru = {
72-
tests = {
73-
inherit (nixosTests) docker;
74-
} // kubernetes.tests;
73+
tests = lib.optionalAttrs stdenv.hostPlatform.isLinux (
74+
{
75+
cross =
76+
let
77+
systemString = if stdenv.buildPlatform.isAarch64 then "gnu64" else "aarch64-multiplatform";
78+
in
79+
pkgsCross.${systemString}.containerd;
80+
81+
inherit (nixosTests) docker;
82+
}
83+
// kubernetes.tests
84+
);
7585

7686
updateScript = nix-update-script { };
7787
};

0 commit comments

Comments
 (0)