libvirt

package
v1.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// OverlayDir is where ephemeral qcow2 overlay files are created.
	OverlayDir string

	// Network is the libvirt network name. Defaults to "default".
	Network string

	// Socket is the libvirtd Unix socket path. Defaults to /var/run/libvirt/libvirt-sock.
	Socket string
}

Config configures the libvirt provisioner.

type Provisioner

type Provisioner struct {
	// contains filtered or unexported fields
}

Provisioner creates ephemeral KVM/QEMU VMs as GitHub Actions runners. Uses QEMU Guest Agent for command execution (no SSH/WinRM needed).

func New

func New(logger *slog.Logger, cfg Config) (*Provisioner, error)

func (*Provisioner) Cleanup

func (p *Provisioner) Cleanup(prefix string)

Cleanup destroys any leftover VMs and overlay files from previous runs.

func (*Provisioner) Close

func (p *Provisioner) Close() error

func (*Provisioner) Start

func (*Provisioner) Stop

func (p *Provisioner) Stop(ctx context.Context, name string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL