internal

package
v0.0.0-...-d68cec5 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2019 License: Apache-2.0, MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultUnitsPath = "/etc/systemd/system"

DefaultUnitsPath is the default CoreOS path where to store units at.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudInitGenerator

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

CloudInitGenerator generates cloud-init scripts.

func NewCloudInitGenerator

func NewCloudInitGenerator(unitsPath string) *CloudInitGenerator

NewCloudInitGenerator creates a new CloudInitGenerator with the given units path.

func (*CloudInitGenerator) Generate

func (t *CloudInitGenerator) Generate(data *OperatingSystemConfig) ([]byte, error)

Generate generates a cloud-init script from the given OperatingSystemConfig.

type DropIn

type DropIn struct {
	Name    string
	Content []byte
}

DropIn is a drop in of a Unit.

type File

type File struct {
	Path        string
	Content     []byte
	Permissions *int32
}

File is a file to be stored during the cloud init script.

type OperatingSystemConfig

type OperatingSystemConfig struct {
	Files     []*File
	Units     []*Unit
	Bootstrap bool
}

OperatingSystemConfig is the data required to create a cloud init script.

type Unit

type Unit struct {
	Name    string
	Content []byte
	DropIns []*DropIn
}

Unit is a unit to be created during the cloud init script.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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