syslinux

package
v0.13.0-alpha.3 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2021 License: MPL-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// BootA is a syslinux label.
	BootA = "boot-a"

	// BootB is a syslinux label.
	BootB = "boot-b"

	// SyslinuxLdlinux is the path to ldlinux.sys.
	SyslinuxLdlinux = constants.BootMountPoint + "/syslinux/ldlinux.sys"

	// SyslinuxConfig is the path to the Syslinux config.
	SyslinuxConfig = constants.BootMountPoint + "/syslinux/syslinux.cfg"
)

Variables

This section is empty.

Functions

func Default added in v0.7.0

func Default(label string) (err error)

Default sets the default syslinx label.

func Install

func Install(fallback string, config interface{}, sequence runtime.Sequence, bootPartitionFound bool) (err error)

Install implements the Bootloader interface. It sets up syslinux with the specified kernel parameters.

func Labels

func Labels() (current, next string, err error)

Labels parses the syslinux config and returns the current active label, and what should be the next label.

func Prepare

func Prepare(dev string) (err error)

Prepare implements the Bootloader interface. It works by writing gptmbr.bin to a block device.

Types

type Cfg

type Cfg struct {
	Default string
	Labels  []*Label
}

Cfg reprsents the cfg file.

type Label

type Label struct {
	Root   string
	Kernel string
	Initrd string
	Append string
}

Label reprsents a label in the cfg file.

type Syslinux

type Syslinux struct{}

Syslinux represents the syslinux bootloader.

Jump to

Keyboard shortcuts

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