feat: get_clusters() and create_vm_from_cloud_init(node=)
driver / lint (pull_request) Successful in 16s
driver / standard (pull_request) Failing after 19s
driver / types (pull_request) Successful in 1m10s
driver / test (3.13) (pull_request) Successful in 1m13s
driver / test (3.12) (pull_request) Successful in 1m19s
driver / lowest (pull_request) Successful in 32s
driver / build (pull_request) Successful in 28s
driver / security (pull_request) Successful in 1m0s
CI / driver (pull_request) Failing after 2m32s
driver / publish (pull_request) Skipped

A hypervisor reports every cluster its connection can see: the cluster's
name and quorum, its nodes (offline ones too, the local one marked) with
CPU and memory, and the storages and networks with the nodes that see
each. A standalone host is a cluster of one without a name; a manager
reports each cluster and standalone host it runs. Declared only, so a
capability check stays truthful.

create_vm_from_cloud_init() takes the node to create the VM on; a driver
that can only create on its own node refuses another.

Refs NetOrk/netork#484, NetOrk/netork#1822
This commit is contained in:
christianmanivong committed 2026-11-01 16:38:38 +01:00
1 parent 97cb8779c5
commit 00aa5efef0
5 files changed
+215

No files matched your search

+9
View File
@@ -14,6 +14,15 @@ recorded here; their history is the git log.
3.12 venv no longer has.
### Added
- `HypervisorDriver.get_clusters()` and its shapes `ClusterDict`, `ClusterNodeDict`,
`ClusterStorageDict`, `ClusterNetworkDict`: every cluster the connection can see,
with its nodes (offline ones included, `local` on the node the connection is),
their CPU and memory, and the storages and networks with the nodes that see each.
A standalone host is a cluster of one with no name; a manager reports each cluster
and standalone host it runs. Declared only (NetOrk/netork#484, #1821).
- `create_vm_from_cloud_init(node=…)`: the cluster node to create the VM on. None
leaves it to the driver; a driver that can only create on its own node raises
ValueError for another (NetOrk/netork#1822).
- `LocalAccountsMixin.add_service_account(name, public_key)`: netOrk's own account,
created through the account the driver logs in with today. It takes a key and no
password, and a rule of its own in `85-service-<name>` lets it run everything as