configcore

package
v0.0.0-...-05c117c Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2024 License: GPL-3.0 Imports: 51 Imported by: 37

Documentation

Index

Constants

View Source
const HOST_NAME_MAX = 64

Note that HOST_NAME_MAX is 64 on Linux, but DNS allows domain names up to 255 characters

Variables

View Source
var (
	Stdout = os.Stdout
	Stderr = os.Stderr
)

Functions

func Early

func Early(dev sysconfig.Device, cfg RunTransaction, values map[string]interface{}) error

func ExportExperimentalFlags

func ExportExperimentalFlags(tr ConfGetter) error

func Run

func Run(dev sysconfig.Device, cfg RunTransaction) error

Types

type ConfGetter

type ConfGetter interface {
	Get(snapName, key string, result interface{}) error
	GetMaybe(snapName, key string, result interface{}) error
	GetPristine(snapName, key string, result interface{}) error
}

ConfGetter is an interface for reading of config values.

type RunTransaction

type RunTransaction interface {
	Get(snapName, key string, result interface{}) error
	GetMaybe(snapName, key string, result interface{}) error
	GetPristine(snapName, key string, result interface{}) error
	Task() *state.Task
	Set(snapName, key string, value interface{}) error
	Changes() []string
	State() *state.State
	Commit()
}

RunTransaction is an interface describing how to access the system configuration state and transaction.

func NewRunTransaction

func NewRunTransaction(tr *config.Transaction, tk *state.Task) RunTransaction

Jump to

Keyboard shortcuts

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