Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for QEMU/libvirt platform. (#1677)
* Add support for QEMU/libvirt platform. Add basic support for running LISA framework on Linux platform using QEMU via the libvirt API. This includes succesfully running the Microsoft T0 tests against the CBL-Mariner image.
- Loading branch information
Showing
11 changed files
with
603 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,5 @@ | |
from lisa.util.constants import PLATFORM_READY | ||
|
||
AZURE = "azure" | ||
QEMU = "qemu" | ||
READY = PLATFORM_READY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
from dataclasses import dataclass | ||
from typing import Any, Dict, Optional | ||
|
||
from lisa.environment import Environment | ||
from lisa.node import Node | ||
|
||
|
||
@dataclass | ||
class EnvironmentContext: | ||
ssh_public_key: str = "" | ||
|
||
|
||
@dataclass | ||
class NodeContext: | ||
vm_name: str = "" | ||
cloud_init_file_path: str = "" | ||
os_disk_base_file_path: str = "" | ||
os_disk_file_path: str = "" | ||
extra_cloud_init_user_data: Optional[Dict[str, Any]] = None | ||
|
||
|
||
def get_environment_context(environment: Environment) -> EnvironmentContext: | ||
return environment.get_context(EnvironmentContext) | ||
|
||
|
||
def get_node_context(node: Node) -> NodeContext: | ||
return node.get_context(NodeContext) |
Oops, something went wrong.