VM Management

Guide to virtual machine lifecycle management in Infinibay

VM Management

Infinibay provides comprehensive virtual machine management through a GraphQL API and native libvirt bindings.

Overview

Virtual machines are managed through the @infinibay/libvirt-node package, which provides Rust-based NAPI bindings for direct communication with the libvirt daemon.

Creating VMs

VMs are created through the GraphQL API with automatic configuration:

mutation CreateVM {
  createVM(input: {
    name: "dev-workstation"
    departmentId: "dept-123"
    memory: 4096
    vcpus: 2
    diskSize: 50
    osType: "windows11"
  }) {
    id
    name
    status
  }
}

VM Lifecycle

VMs have the following states:

  • STOPPED - VM is powered off
  • RUNNING - VM is active
  • PAUSED - VM is suspended
  • PENDING - VM is being created/modified

Automatic Configuration

When creating a VM, Infinibay automatically:

  • Configures TPM 2.0 for Windows 11
  • Sets up network interfaces
  • Applies department firewall rules
  • Configures storage pools

VM Operations

Available operations:

  • Start - Power on the VM
  • Stop - Graceful shutdown
  • Force Stop - Immediate shutdown
  • Restart - Reboot the VM
  • Pause - Suspend to memory
  • Resume - Resume from pause

Resource Management

VMs can be resized (requires restart):

  • Modify CPU count
  • Adjust memory allocation
  • Expand disk size (cannot shrink)

Next Steps