seed

package
v0.5.0 Latest Latest
Warning

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

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

Documentation

Overview

Package seed creates cloud-init NoCloud seed ISOs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(path string, cfg Config) error

Create generates a NoCloud seed ISO at the given path.

Types

type Config

type Config struct {
	Hostname string
	User     string
	SSHKey   string
	// Fixtures are read-only ext4 images to mount in the guest via cloud-init's
	// mounts: directive (which writes /etc/fstab, so they re-mount on every boot
	// without a cloud-init re-run), each addressed by its volume LABEL. Empty for
	// a VM with no fixtures.
	Fixtures []Fixture
	// Network, when non-nil, makes the guest configure its NIC with a static
	// IPv4 address via a NoCloud network-config (Linux/cloud-hypervisor). Nil
	// means "no network-config", leaving the guest on DHCP (macOS).
	Network *NetworkConfig
}

Config specifies the cloud-init configuration for a VM.

type Fixture

type Fixture struct {
	Label     string
	GuestPath string
}

Fixture is a guest-side read-only ext4 mount: the volume Label (assigned host-side) and the absolute GuestPath where cloud-init mounts it by LABEL.

type NetworkConfig

type NetworkConfig struct {
	MAC     string
	IP      string
	Gateway string
	Netmask string
}

NetworkConfig is a static IPv4 assignment for the guest's single NIC, matched by MAC so it applies regardless of the kernel's interface naming.

Jump to

Keyboard shortcuts

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