···1314 lxd-image-metadata = releases.lxdContainerMeta.${pkgs.stdenv.hostPlatform.system};
15 lxd-image-rootfs = releases.lxdContainerImage.${pkgs.stdenv.hostPlatform.system};
01617in {
18 name = "lxd-container";
···2324 nodes.machine = { lib, ... }: {
25 virtualisation = {
26- diskSize = 4096;
2728 # Since we're testing `limits.cpu`, we've gotta have a known number of
29 # cores to lean on
···6061 with subtest("Container can be managed"):
62 machine.succeed("lxc launch nixos container")
000000000063 with machine.nested("Waiting for instance to start and be usable"):
64 retry(instance_is_up)
65 machine.succeed("echo true | lxc exec container /run/current-system/sw/bin/bash -")
···1314 lxd-image-metadata = releases.lxdContainerMeta.${pkgs.stdenv.hostPlatform.system};
15 lxd-image-rootfs = releases.lxdContainerImage.${pkgs.stdenv.hostPlatform.system};
16+ lxd-image-rootfs-squashfs = releases.lxdContainerImageSquashfs.${pkgs.stdenv.hostPlatform.system};
1718in {
19 name = "lxd-container";
···2425 nodes.machine = { lib, ... }: {
26 virtualisation = {
27+ diskSize = 6144;
2829 # Since we're testing `limits.cpu`, we've gotta have a known number of
30 # cores to lean on
···6162 with subtest("Container can be managed"):
63 machine.succeed("lxc launch nixos container")
64+ with machine.nested("Waiting for instance to start and be usable"):
65+ retry(instance_is_up)
66+ machine.succeed("echo true | lxc exec container /run/current-system/sw/bin/bash -")
67+ machine.succeed("lxc delete -f container")
68+69+ with subtest("Squashfs image is functional"):
70+ machine.succeed(
71+ "lxc image import ${lxd-image-metadata}/*/*.tar.xz ${lxd-image-rootfs-squashfs} --alias nixos-squashfs"
72+ )
73+ machine.succeed("lxc launch nixos-squashfs container")
74 with machine.nested("Waiting for instance to start and be usable"):
75 retry(instance_is_up)
76 machine.succeed("echo true | lxc exec container /run/current-system/sw/bin/bash -")