syslinux

package
v6.0.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2019 License: BSD-3-Clause Imports: 10 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package syslinux implements a syslinux config file parser.

See http://www.syslinux.org/wiki/index.php?title=Config for general syslinux config features.

Currently, only the APPEND, INCLUDE, KERNEL, LABEL, DEFAULT, and INITRD directives are partially supported.

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrDefaultEntryNotFound is returned when the configuration file
	// names a default label that is not part of the configuration.
	ErrDefaultEntryNotFound = errors.New("default label not found in configuration")
)

Functions

This section is empty.

Types

type Config

type Config struct {
	// Entries is a map of label name -> label configuration.
	Entries map[string]*boot.LinuxImage

	// DefaultEntry is the default label key to use.
	//
	// If DefaultEntry is non-empty, the label is guaranteed to exist in
	// `Entries`.
	DefaultEntry string
}

Config encapsulates a parsed Syslinux configuration file.

See http://www.syslinux.org/wiki/index.php?title=Config for the configuration file specification.

func ParseConfigFile

func ParseConfigFile(url string, wd *url.URL) (*Config, error)

ParseConfigFile parses a Syslinux configuration as specified in http://www.syslinux.org/wiki/index.php?title=Config

Currently, only the APPEND, INCLUDE, KERNEL, LABEL, DEFAULT, and INITRD directives are partially supported.

urlfetch.DefaultSchemes is used to fetch any files that must be parsed or provided.

`wd` is the default scheme, host, and path for any files named as a relative path - e.g. kernel, include, and initramfs paths are requested relative to the wd. The default path for config files is assumed to be `wd.Path`/pxelinux.cfg/.

Jump to

Keyboard shortcuts

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