Documentation ¶
Overview ¶
Package sdboot provides the interface to the Systemd-Boot bootloader: config management, installation, etc.
Index ¶
Constants ¶
View Source
const ( // SystemdBootGUIDString is the GUID of the SystemdBoot EFI variables. SystemdBootGUIDString = "4a67b082-0a4c-41cf-b6c7-440b29bb8c4f" // SystemdBootStubInfoPath is the path to the SystemdBoot StubInfo EFI variable. SystemdBootStubInfoPath = constants.EFIVarsMountPoint + "/" + "StubInfo-" + SystemdBootGUIDString )
View Source
const ( LoaderEntryDefaultName = "LoaderEntryDefault" LoaderEntrySelectedName = "LoaderEntrySelected" LoaderConfigTimeoutName = "LoaderConfigTimeout" )
Variable names.
Variables ¶
View Source
var SystemdBootGUID = efiguid.MustFromString(SystemdBootGUIDString)
SystemdBootGUID is the GUID of the SystemdBoot EFI variables.
Functions ¶
func IsBootedUsingSDBoot ¶
func IsBootedUsingSDBoot() bool
IsBootedUsingSDBoot returns true if the system is booted using sd-boot.
func ReadVariable ¶
ReadVariable reads a SystemdBoot EFI variable.
Types ¶
type Config ¶
Config describe sd-boot state.
func (*Config) Install ¶
func (c *Config) Install(options options.InstallOptions) error
Install the bootloader.
Assumes that EFI partition is already mounted. Writes down the UKI and updates the EFI variables.
func (*Config) PreviousLabel ¶
PreviousLabel returns the label of the previous bootloader version.
Click to show internal directories.
Click to hide internal directories.