containerinit

package
v0.0.0-...-be26699 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2015 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateNetworkConfig

func GenerateNetworkConfig(networkConfig *container.NetworkConfig) (string, error)

GenerateNetworkConfig renders a network config for one or more network interfaces, using the given non-nil networkConfig containing a non-empty Interfaces field.

func TemplateUserData

func TemplateUserData(
	series string,
	authorizedKeys string,
	aptProxy proxy.Settings,
	aptMirror string,
	enablePackageUpdates bool,
	enableOSUpgrades bool,
	networkConfig *container.NetworkConfig,
) ([]byte, error)

templateUserData returns a minimal user data necessary for the template. This should have the authorized keys, base packages, the cloud archive if necessary, initial apt proxy config, and it should do the apt-get update/upgrade initially.

func WriteCloudInitFile

func WriteCloudInitFile(directory string, userData []byte) (string, error)

WriteCloudInitFile writes the data out to a cloud-init file in the directory specified, and returns the filename.

func WriteUserData

func WriteUserData(
	instanceConfig *instancecfg.InstanceConfig,
	networkConfig *container.NetworkConfig,
	directory string,
) (string, error)

WriteUserData generates the cloud-init user-data using the specified machine and network config for a container, and writes the serialized form out to a cloud-init file in the directory specified.

Types

This section is empty.

Jump to

Keyboard shortcuts

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