fix(integration-vm): pin LIBVIRT_DEFAULT_URI=qemu:///system
Bare virsh/virt-install default to qemu:///session for a non-root caller, but the substrate, /dev/kvm, and the boma-it NAT network live on the SYSTEM libvirtd. Pin the URI so the driver targets system regardless of who runs it. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ed1187d1c3
commit
147eb874ea
1 changed files with 5 additions and 0 deletions
|
|
@ -44,6 +44,11 @@ DEFAULT_VCPUS = 2
|
|||
MIN_FREE_MIB = 4096
|
||||
VALID_TIERS = ("internal", "le-staging", "le-prod-wildcard")
|
||||
|
||||
# Target the SYSTEM libvirtd — where the substrate, /dev/kvm, and the NAT network live.
|
||||
# Without this, a non-root caller's bare virsh/virt-install default to qemu:///session.
|
||||
os.environ.setdefault("LIBVIRT_DEFAULT_URI", "qemu:///system")
|
||||
|
||||
|
||||
def vm_name(host, suffix=None):
|
||||
suffix = suffix or uuid.uuid4().hex[:8]
|
||||
return f"{NAME_PREFIX}{host}-{suffix}"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue