Documentation ¶
Index ¶
- Constants
- type Conf
- func (c *Conf) AddAuthorizedKeys(user string, keys []string)
- func (c *Conf) AddAutoLogin()
- func (c *Conf) AddAutoResize()
- func (c *Conf) AddConfigSource(source string)
- func (c *Conf) AddFile(path, contents string, mode int)
- func (c *Conf) AddSystemdUnit(name, contents string, state systemdUnitState)
- func (c *Conf) AddSystemdUnitDropin(service, name, contents string)
- func (c *Conf) Bytes() []byte
- func (c *Conf) CopyKeys(keys []*agent.Key)
- func (c *Conf) DisableAutomaticUpdates()
- func (c *Conf) IsEmpty() bool
- func (c *Conf) IsIgnition() bool
- func (c *Conf) MaybeCompress() (string, error)
- func (c *Conf) MergeV3(newConfig v3types.Config)
- func (c *Conf) MergeV31(newConfig v31types.Config)
- func (c *Conf) MergeV32(newConfig v32types.Config)
- func (c *Conf) MergeV33(newConfig v33types.Config)
- func (c *Conf) MergeV34(newConfig v34types.Config)
- func (c *Conf) MergeV35exp(newConfig v35exptypes.Config)
- func (c *Conf) MountHost(dest string, readonly bool)
- func (c *Conf) String() string
- func (c *Conf) ValidConfig() bool
- func (c *Conf) WriteFile(name string) error
- type UserData
- type WarningsAction
Constants ¶
const ( NoState systemdUnitState = iota Enable Mask )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Conf ¶
type Conf struct {
// contains filtered or unexported fields
}
Conf is a configuration for a CoreOS machine. Only Ignition spec 3 and later are supported.
func (*Conf) AddAuthorizedKeys ¶
AddAuthorizedKeys adds an Ignition config to add the given keys to the SSH authorized_keys file for the given user.
func (*Conf) AddAutoLogin ¶
func (c *Conf) AddAutoLogin()
AddAutoLogin adds an Ignition config for automatic login on consoles
func (*Conf) AddAutoResize ¶
func (c *Conf) AddAutoResize()
AddAutoResize adds an Ignition config for a `resize` function to resize serial consoles
func (*Conf) AddConfigSource ¶
AddConfigSource adds an Ignition config to merge (v3) the config available at the `source` URL with the current config.
func (*Conf) AddSystemdUnit ¶
func (*Conf) AddSystemdUnitDropin ¶
func (*Conf) CopyKeys ¶
CopyKeys copies public keys from agent ag into the configuration to the appropriate configuration section for the core user.
func (*Conf) DisableAutomaticUpdates ¶
func (c *Conf) DisableAutomaticUpdates()
DisableAutomaticUpdates turns off zincati
func (*Conf) IsIgnition ¶
IsIgnition returns true if the config is for Ignition. Returns false in the case of empty configs
func (*Conf) MaybeCompress ¶
Config is compressed and added to another via data url
func (*Conf) MergeV3 ¶
MergeV3 merges a config with the ignitionV3 config via Ignition's merging function.
func (*Conf) MergeV31 ¶
MergeV31 merges a config with the ignitionV31 config via Ignition's merging function.
func (*Conf) MergeV32 ¶
MergeV32 merges a config with the ignitionV32 config via Ignition's merging function.
func (*Conf) MergeV33 ¶
MergeV33 merges a config with the ignitionV33 config via Ignition's merging function.
func (*Conf) MergeV34 ¶
MergeV34exp merges a config with the ignitionV34exp config via Ignition's merging function.
func (*Conf) MergeV35exp ¶
func (c *Conf) MergeV35exp(newConfig v35exptypes.Config)
MergeV35exp merges a config with the ignitionV35exp config via Ignition's merging function.
func (*Conf) ValidConfig ¶
type UserData ¶
type UserData struct {
// contains filtered or unexported fields
}
UserData is an immutable, unvalidated configuration for a CoreOS machine.
func Empty ¶
func Empty() *UserData
Empty creates a completely empty configuration. Any configuration addition applied to an empty config is ignored.
func EmptyIgnition ¶
func EmptyIgnition() *UserData
EmptyIgnition returns an a default empty config using the latest stable supported Ignition spec.
func Ignition ¶
Ignition returns an Ignition UserData struct from the provided string. If the given string is empty, it will create a default empty config using the latest stable supported Ignition spec.
func MergeAllConfigs ¶
Merge all configs into a V3.1 config
type WarningsAction ¶
type WarningsAction int
const ( IgnoreWarnings WarningsAction = iota ReportWarnings FailWarnings )