datasource

package
v0.8.7 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2014 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BaseUrl              = "http://169.254.169.254/"
	Ec2ApiVersion        = "2009-04-04"
	Ec2UserdataUrl       = BaseUrl + Ec2ApiVersion + "/user-data"
	Ec2MetadataUrl       = BaseUrl + Ec2ApiVersion + "/meta-data"
	OpenstackApiVersion  = "openstack/2012-08-10"
	OpenstackUserdataUrl = BaseUrl + OpenstackApiVersion + "/user_data"
)
View Source
const (
	ProcCmdlineLocation        = "/proc/cmdline"
	ProcCmdlineCloudConfigFlag = "cloud-config-url"
)

Variables

This section is empty.

Functions

func NewConfigDrive added in v0.7.4

func NewConfigDrive(root string) *configDrive

func NewLocalFile

func NewLocalFile(path string) *localFile

func NewMetadataService

func NewMetadataService() *metadataService

func NewProcCmdline

func NewProcCmdline() *procCmdline

func NewRemoteFile added in v0.8.0

func NewRemoteFile(url string) *remoteFile

Types

type Datasource

type Datasource interface {
	IsAvailable() bool
	AvailabilityChanges() bool
	ConfigRoot() string
	FetchMetadata() ([]byte, error)
	FetchUserdata() ([]byte, error)
	Type() string
}

Jump to

Keyboard shortcuts

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