<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/meta-virtualization.git/tests, branch master</title>
<subtitle>Mirror of git.yoctoproject.org/meta-virtualization</subtitle>
<id>https://git.enea.com/cgit/linux/meta-virtualization.git/atom?h=master</id>
<link rel='self' href='https://git.enea.com/cgit/linux/meta-virtualization.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/'/>
<updated>2026-05-10T20:15:50+00:00</updated>
<entry>
<title>vcontainer: add BBMASK for parse savings and suppress layer warnings</title>
<updated>2026-05-10T20:15:50+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-05-10T20:15:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=18c7f71383d650a97e28c95e3b61445cb6849bd4'/>
<id>urn:sha1:18c7f71383d650a97e28c95e3b61445cb6849bd4</id>
<content type='text'>
The initial vcontainer distro had no BBMASK at all, making it
effectively poky with fewer DISTRO_FEATURES. Every multiconfig parsed
the entire recipe universe even though container image builds only
need a small subset. With 4+ multiconfigs, the parse overhead is
significant.

Add vcontainer-bbmask.inc as a lighter alternative to vruntime's
aggressive BBMASK. It masks the same categories irrelevant to any
container/VM build (graphics, multimedia, desktop, virtualization
platforms, orchestration tools, meta-python, meta-filesystems,
meta-webserver) but keeps the OCI tooling that vruntime blocks:
umoci, container-registry, image recipes, sloci, oci-image-tools.

Masking entire layers (meta-python, meta-filesystems, meta-webserver)
produces BBFILE_PATTERN warnings because the layers are registered in
bblayers.conf (shared with the main build) but have zero recipes after
masking. BitBake provides BBFILE_PATTERN_IGNORE_EMPTY_&lt;collection&gt;
to suppress this, but checks it on self.data (the base datastore),
not per-multiconfig datastores. Setting it in the distro config has
no effect. Move the suppression to meta-virt-host.conf which is
included by the main build's local.conf and therefore visible to
the base datastore.

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>container-registry: add multi-arch OCI push support and tests</title>
<updated>2026-05-10T13:58:45+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-05-10T13:58:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=cbe004439cae170ad5455fbb881495795e42bf5a'/>
<id>urn:sha1:cbe004439cae170ad5455fbb881495795e42bf5a</id>
<content type='text'>
The registry push script (container-registry-index.bb) treated all OCI
directories as single-arch, calling 'skopeo copy oci:&lt;dir&gt;' which fails
with "more than one image in oci, choose an image" when the directory
contains a multi-arch image index. The original push implementation
predated multi-arch OCI support and only handled the single-manifest
case.

Detect multi-arch OCI Image Index directories (both flat and nested
layouts) in the direct-path push mode and use 'skopeo copy --all' to
push the entire manifest list to the registry in one operation. This
preserves the multi-platform structure so that clients pulling from the
registry automatically get the correct architecture.

Also strip the '-multiarch' suffix from directory names when deriving
the registry image name, so container-base-multiarch-multiarch-oci
pushes as 'container-base' rather than 'container-base-multiarch'.

Add build-profiles.md documentation for the vcontainer distro, container
multiconfigs, and multi-arch container build workflow.

Add test_vcontainer_distro.py with 54 tests across three tiers:
- Tier 1: Static file assertions (vruntime-base.inc, vcontainer.conf,
  multiconfigs, bbclass defaults, recipe structure)
- Tier 2: Cross-file consistency (shared base, distro-MC alignment,
  bbclass-to-multiconfig file matching)
- Tier 3: Build output verification (OCI index structure, platform
  entries, blob integrity, manifest validation)

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests: add vcontainer --config / VDKR_CONFIG auth plumbing tests</title>
<updated>2026-04-29T20:15:34+00:00</updated>
<author>
<name>Tim Orling</name>
<email>tim.orling@konsulko.com</email>
</author>
<published>2026-04-16T20:31:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=002f915a432467dca4a9c61f75947f10f96e63e2'/>
<id>urn:sha1:002f915a432467dca4a9c61f75947f10f96e63e2</id>
<content type='text'>
Add a new pytest module (tests/test_vcontainer_auth_config.py) covering
the registry-auth-config feature introduced in the previous commit.
Split into two tiers:

TestAuthConfigStaticPlumbing (40 static/shell-level assertions):
- vrunner.sh: AUTH_CONFIG picks up VDKR_CONFIG/VPDMN_CONFIG; --config
  parsing; validate_auth_config and setup_auth_share definitions; every
  validator reject rule (symlink / non-regular / unreadable / missing /
  &lt;2B / &gt;1MiB / mode whitelist 400|600|200 / non-owner WARN); 0700
  staging dir and 0400 staged file; readonly=on on the 9p share;
  dedicated ${TOOL_NAME}_auth tag. Critically also asserts that
  AUTH_CONFIG, VDKR_CONFIG and VPDMN_CONFIG never appear in
  KERNEL_APPEND - only the ${CMDLINE_PREFIX}_auth=1 flag does.
- vcontainer-common.sh: env-var init, --config parsing, AUTH_CONFIG
  forwarding via --config to vrunner, and show_usage documentation.
- vcontainer-init-common.sh: RUNTIME_AUTH default, cmdline parsing,
  mount_auth_share/unmount_auth_share presence, dedicated per-runtime
  ${VCONTAINER_RUNTIME_NAME}_auth tag, and the ro,nosuid,nodev,noexec
  mount options.
- vdkr-init.sh: install_auth_config present, writes to
  /root/.docker/config.json with 0600 and 0700 parent, mount + unmount
  pairing, precedence NOTE logged, and ordering after
  install_registry_ca so --config wins over --registry-user/-pass.
- vpdmn-init.sh: writes to /run/containers/0/auth.json with matching
  modes, exports REGISTRY_AUTH_FILE, mount/unmount pairing, and
  ordering after verify_podman.
- README.md: --config section exists and documents both env vars and
  both runtime target paths.

TestAuthConfigValidator (13 functional cases):
- Extracts validate_auth_config() from vrunner.sh with a brace-matching
  parser, sources it in a bash subshell with a stubbed log() helper,
  and drives it with real files: accepts modes 0600 / 0400, accepts
  the 2-byte minimum "{}", rejects missing / symlink / directory /
  empty / 1-byte / &gt;1 MiB / 0644 (world-readable) / 0640 / 0700
  (owner-exec) / 0000 (unreadable, skipped when running as root).

Path resolution is resilient: VCONTAINER_FILES_DIR env override first,
otherwise repo-relative to the test file, falling back to the
/opt/bruce/poky path used elsewhere in the suite. No tests need QEMU,
a registry, or network. All 53 tests complete in ~0.1s.

Add tests/__pycache__ to .gitignore.

AI-Generated: Claude Cowork Opus 4.7
Signed-off-by: Tim Orling &lt;tim.orling@konsulko.com&gt;
Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>test_vdkr_registry: fix test_image_requires_subcommand</title>
<updated>2026-04-28T11:47:27+00:00</updated>
<author>
<name>Tim Orling</name>
<email>ticotimo@gmail.com</email>
</author>
<published>2026-04-28T00:33:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=052241689a0c419d13e15e83e7ad65dd16fc8ffd'/>
<id>urn:sha1:052241689a0c419d13e15e83e7ad65dd16fc8ffd</id>
<content type='text'>
vdkr.run() merges stderr into stdout (see conftest.py), so the
error message ends up in result.stdout even though the script
writes it to stderr (&gt;&amp;2).

Signed-off-by: Tim Orling &lt;tim.orling@konsulko.com&gt;
Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests: fix FD inheritance in test harness for all vdkr/vpdmn commands</title>
<updated>2026-04-22T23:10:15+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-22T20:18:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=2e0704ee9282e4e86c13180334cb7ce118e55dd9'/>
<id>urn:sha1:2e0704ee9282e4e86c13180334cb7ce118e55dd9</id>
<content type='text'>
Change VdkrRunner.run() and VpdmnRunner.run() to use Popen with
start_new_session=True, stdin=DEVNULL, and file-based stdout instead
of subprocess.run(capture_output=True). This prevents daemon background
processes from inheriting pipe FDs, which causes communicate() to hang
in CI/test harness environments (e.g., buildbot).

The fix applies to all commands, not just memres start, because any
vdkr command can auto-start the daemon (auto-daemon is enabled by
default).

Also fix test_volume_mount_requires_memres to check both stdout and
stderr for the error message, since stderr is now merged into stdout
by the Popen approach.

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests: fix memres start hanging in subprocess.run</title>
<updated>2026-04-22T19:14:52+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-22T19:14:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=b02e400b63849991c1590a3572e711740758583f'/>
<id>urn:sha1:b02e400b63849991c1590a3572e711740758583f</id>
<content type='text'>
memres start spawns background processes (QEMU VM, idle watchdog)
that persist after the vrunner script exits. When invoked via
subprocess.run(capture_output=True), these background processes
inherit the pipe file descriptors, preventing communicate() from
returning until all pipe holders exit — which can be 30+ minutes
(the idle timeout).

Fix by using Popen with:
- stdin=subprocess.DEVNULL (no inherited stdin pipe)
- file-based stdout (no pipe FDs to inherit)
- start_new_session=True (new process group, so wait() only
  waits for the parent script, not the background children)

This matches the behavior when running from a shell, where the
daemon processes are fully detached from the caller's FD table.

Applied to both VdkrRunner and VpdmnRunner memres_start methods.

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests: add @pytest.mark.memres to daemon-dependent tests</title>
<updated>2026-04-22T19:07:21+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-22T19:07:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=5f512359af5d02c037f85887bf5a428af05d4fb3'/>
<id>urn:sha1:5f512359af5d02c037f85887bf5a428af05d4fb3</id>
<content type='text'>
Test classes that depend on vmemres (daemon mode) were not marked,
causing them to run even when filtered with '-m "not memres"'. This
caused timeout failures on CI/buildbot environments where KVM may
not be available and daemon startup exceeds the test timeout.

Mark the following classes with @pytest.mark.memres in both
test_vdkr.py and test_vpdmn.py:
- TestMemresBasic
- TestPortForwarding (vdkr only)
- TestContainerLifecycle
- TestVolumeMounts
- TestSystem
- TestVstorage
- TestRun
- TestAutoStartDaemon (vdkr only)
- TestDynamicPortForwarding (vdkr only)
- TestPortForwardRegistry (vdkr only)

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>incus: add runtime test suite</title>
<updated>2026-04-09T03:35:47+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-09T03:35:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=68f0c8faf2e2b9024ee24ef97df1895bb117629c'/>
<id>urn:sha1:68f0c8faf2e2b9024ee24ef97df1895bb117629c</id>
<content type='text'>
pexpect-based tests covering:
- Daemon startup via systemd
- incus-admin group creation
- incus admin init --minimal
- Alpine container launch, exec, stop, delete

Run: pytest tests/test_incus_runtime.py -v --machine qemux86-64

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests: update k3s multi-node to use kernel cmdline role setup</title>
<updated>2026-04-07T17:32:59+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-07T17:32:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=31baaea4ab87aa2a42579b526b5c167796e60097'/>
<id>urn:sha1:31baaea4ab87aa2a42579b526b5c167796e60097</id>
<content type='text'>
Update the multi-node test fixture to use kernel cmdline parameters
(k3s.role, k3s.node-ip, k3s.node-name) instead of manual IP
configuration and k3s restart. The k3s-role-setup.service handles
networking and role switching automatically on boot.

- Pass kernel_append to K3sRunner for k3s.role and k3s.node-ip
- Remove manual ip-addr-add and k3s stop/restart from fixture
- Use k3s-get-token helper to extract join token on server
- Agent starts k3s agent manually with extracted token (token
  not known at boot time)
- Remove _QEMU_ARCH_CONFIG dict (moved to run-qemu-vm.sh script)

All 10 tests pass: 5 single-node + 5 multi-node.

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
<entry>
<title>tests, k3s: update test suite and README for multi-node</title>
<updated>2026-04-07T16:06:01+00:00</updated>
<author>
<name>Bruce Ashfield</name>
<email>bruce.ashfield@gmail.com</email>
</author>
<published>2026-04-07T16:06:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-virtualization.git/commit/?id=6b4415876f617b5afe17d1525a555a120df78bc0'/>
<id>urn:sha1:6b4415876f617b5afe17d1525a555a120df78bc0</id>
<content type='text'>
test_k3s_runtime.py:
- Use run-qemu-vm.sh script for multi-node QEMU launches instead of
  inline command building (shared infrastructure with manual testing)
- Resolve script path to absolute for pexpect compatibility
- Accept &gt;= 1 Ready node in single-node test (persistent rootfs state)

README.md:
- Complete rewrite with current build profile workflow
- Document single-node quick start and multi-node cluster setup
- Document kernel cmdline parameters for role-based boot
- Document k3s-get-token helper, packages, and useful commands
- Add automated testing instructions

Signed-off-by: Bruce Ashfield &lt;bruce.ashfield@gmail.com&gt;
</content>
</entry>
</feed>
