kubernetes/test/e2e/dra
Ed Bartosh 35fd124f4d DRA: fix CDI spec version
The latest CDI release includes spec version check that fails
if version is less than 0.3.0:
  https://github.com/container-orchestrated-devices/container-device-interface/blob/v0.5.4/pkg/cdi/version.go#L42

Updating CDI spec version to 0.3.0 in the test kubelet plugin code
should fix e2e test failures on the CRI runtimes that use CDI >= 0.5.4
(Containerd master atm, CRI-O soon).
2023-03-05 16:49:56 +02:00
..
test-driver DRA: fix CDI spec version 2023-03-05 16:49:56 +02:00
deploy.go e2e dra: improve goroutine handling 2023-03-01 15:00:30 +01:00
dra.go e2e: use error wrapping with %w 2023-02-06 15:39:13 +01:00
kind-build-image.sh
kind.yaml
OWNERS
README.md

Overview

The tests in this directory cover dynamic resource allocation support in Kubernetes. They do not test the correct behavior of arbitrary dynamic resource allocation drivers.

If such a driver is needed, then the in-tree test/e2e/dra/test-driver is used, with a slight twist: instead of deploying that driver directly in the cluster, the necessary sockets for interaction with kubelet (registration and dynamic resource allocation) get proxied into the e2e.test binary. This reuses the work done for CSI mock testing. The advantage is that no separate images are needed for the test driver and that the e2e test has full control over all gRPC calls, in case that it needs that for operations like error injection or checking calls.

Cluster setup

The container runtime must support CDI. The latest cri-o releases contain support, containerd 1.6.x does not. To bring up a kind cluster with containerd built from their main branch, use:

test/e2e/dra/kind-build-image.sh dra/node:latest && \
kind create cluster --config test/e2e/dra/kind.yaml --image dra/node:latest