Implement guest tool installation and management system
- Added `guest_tools.py` for standalone tool installer functionality. - Introduced `ToolJobStore` in `tool_store.py` to manage per-VM tool job records. - Created `ToolService` in `tools.py` for background installation workers using the guest execution channel. - Enhanced `LifecycleService` in `lifecycle.py` to support tool installation queuing and preparation. - Updated `guest_exec.py` to handle connection shutdown gracefully. - Added validation and normalization functions for tool specifications. - Implemented logging and error handling for tool installation processes. - Ensured compatibility with Ubuntu 22.04 and ARM64/x86_64 architectures.
This commit is contained in:
@@ -14,6 +14,7 @@ from .lifecycle import LifecycleService
|
||||
from .network import NetworkManager
|
||||
from .state import StateStore
|
||||
from .system import CommandRunner
|
||||
from .tools import ToolService
|
||||
|
||||
|
||||
@dataclass(slots=True)
|
||||
@@ -24,6 +25,7 @@ class Application:
|
||||
state_store: StateStore
|
||||
installer: Installer
|
||||
lifecycle: LifecycleService
|
||||
tools: ToolService | None = None
|
||||
|
||||
|
||||
def build_application(emit: Callable[[str], None] | None = print) -> Application:
|
||||
@@ -41,4 +43,5 @@ def build_application(emit: Callable[[str], None] | None = print) -> Application
|
||||
state_store=state_store,
|
||||
installer=installer,
|
||||
lifecycle=lifecycle,
|
||||
tools=ToolService(settings, state_store, lifecycle),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user