coreos

package
v1.20.0 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2024 License: Apache-2.0, MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudConfig

type CloudConfig struct {
	// Config contains CoreOS specific configuration.
	CoreOS Config `yaml:"coreos,omitempty"`
	// WriteFiles is a list of files that will be written onto the disk of the machine where
	// the cloud config is executed on.
	WriteFiles []File `yaml:"write_files,omitempty"`
}

CloudConfig is a structure containing the relevant fields for generating the Config Container Linux specific cloud config. It can be marshalled to YAML. Note, Flatcar cloud config does not support `runcmd`, see https://github.com/kinvolk/coreos-cloudinit/blob/flatcar-master/Documentation/cloud-config.md#file-format Therefore, do not try to implement runcmd.

func (CloudConfig) String

func (c CloudConfig) String() (string, error)

String returns the string representation of the CloudConfig structure.

type Config

type Config struct {
	// Update contains configuration for the Container Linux update procedure.
	Update Update `yaml:"update,omitempty"`
	// Units is a list of units that are translated to systemd later.
	Units []Unit `yaml:"units,omitempty"`
}

Config contains CoreOS specific configuration.

type File

type File struct {
	// Encoding is the encoding of the file, e.g. base64.
	Encoding string `yaml:"encoding,omitempty"`
	// Content is the actual content of the file.
	Content string `yaml:"content,omitempty"`
	// Owner describes the owner of the file.
	Owner string `yaml:"owner,omitempty"`
	// Path is the path on the disk where the file should get written to.
	Path string `yaml:"path,omitempty"`
	// RawFilePermissions describes the permissions for the file, e.g. 0777.
	RawFilePermissions string `yaml:"permissions,omitempty"`
}

File is a file that gets written to onto the disk of the machine where the cloud config is executed on.

type Unit

type Unit struct {
	// Name is the name of the unit.
	Name string `yaml:"name,omitempty"`
	// Mask defines whether unit is masked or not.
	Mask bool `yaml:"mask,omitempty"`
	// Enable defines whether unit is enabled or not.
	Enable bool `yaml:"enable,omitempty"`
	// Runtime defines the runtime of the unit.
	Runtime bool `yaml:"runtime,omitempty"`
	// Content defines the actual systemd specific content of the unit.
	Content string `yaml:"content,omitempty"`
	// Command describes the command of the unit.
	Command string `yaml:"command,omitempty"`
	// DropIns is a list of drop-in units.
	DropIns []UnitDropIn `yaml:"drop_ins,omitempty"`
}

Unit gets translated to a systemd unit.

type UnitDropIn

type UnitDropIn struct {
	// Name is the name of the drop-in.
	Name string `yaml:"name,omitempty"`
	// Content is the content of the drop-in.
	Content string `yaml:"content,omitempty"`
}

UnitDropIn is a structure for information about a drop-in unit.

type Update

type Update struct {
	// RebootStrategy defines the strategy for reboots.
	RebootStrategy string `yaml:"reboot_strategy,omitempty"`
	// Group describes the update group.
	Group string `yaml:"group,omitempty"`
	// Server describes the update server.
	Server string `yaml:"server,omitempty"`
}

Update contains configuration for the Container Linux update procedure.

Jump to

Keyboard shortcuts

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