conf

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2017 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

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 Container Linux machine. It may be either a coreos-cloudconfig or an ignition configuration.

func (*Conf) AddSystemdUnit added in v0.7.0

func (c *Conf) AddSystemdUnit(name, contents string, enable bool)

func (*Conf) Bytes added in v0.3.0

func (c *Conf) Bytes() []byte

Bytes returns the serialized userdata in Conf.

func (*Conf) CopyKeys

func (c *Conf) CopyKeys(keys []*agent.Key)

CopyKeys copies public keys from agent ag into the configuration to the appropriate configuration section for the core user.

func (*Conf) IsIgnition added in v0.3.0

func (c *Conf) IsIgnition() bool

IsIgnition returns true if the config is for Ignition.

func (*Conf) String

func (c *Conf) String() string

String returns the string representation of the userdata in Conf.

func (*Conf) WriteFile added in v0.3.0

func (c *Conf) WriteFile(name string) error

WriteFile writes the userdata in Conf to a local file.

type UserData added in v0.6.0

type UserData struct {
	// contains filtered or unexported fields
}

UserData is an immutable, unvalidated configuration for a Container Linux machine.

func CloudConfig added in v0.6.0

func CloudConfig(data string) *UserData

func ContainerLinuxConfig added in v0.6.0

func ContainerLinuxConfig(data string) *UserData

func Empty added in v0.6.0

func Empty() *UserData

func Ignition added in v0.6.0

func Ignition(data string) *UserData

func Script added in v0.6.0

func Script(data string) *UserData

func Unknown added in v0.6.0

func Unknown(data string) *UserData

func (*UserData) IsIgnition added in v0.6.0

func (u *UserData) IsIgnition() bool

func (*UserData) Render added in v0.6.0

func (u *UserData) Render() (*Conf, error)

Render parses userdata and returns a new Conf. It returns an error if the userdata can't be parsed.

func (*UserData) Subst added in v0.6.0

func (u *UserData) Subst(old, new string) *UserData

Performs a string substitution and returns a new UserData.

Jump to

Keyboard shortcuts

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