assets

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2017 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Addons = map[string]*Addon{
	"addon-manager": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/addon-manager.yaml",
			"/etc/kubernetes/manifests/",
			"addon-manager.yaml",
			"0640"),
	}, true, "addon-manager"),
	"dashboard": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/dashboard/dashboard-rc.yaml",
			constants.AddonsPath,
			"dashboard-rc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/dashboard/dashboard-svc.yaml",
			constants.AddonsPath,
			"dashboard-svc.yaml",
			"0640"),
	}, true, "dashboard"),
	"kube-dns": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/kube-dns/kube-dns-rc.yaml",
			constants.AddonsPath,
			"kube-dns-rc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/kube-dns/kube-dns-svc.yaml",
			constants.AddonsPath,
			"kube-dns-svc.yaml",
			"0640"),
	}, true, "kube-dns"),
	"heapster": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/heapster/influxGrafana-rc.yaml",
			constants.AddonsPath,
			"influxGrafana-rc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/heapster/grafana-svc.yaml",
			constants.AddonsPath,
			"grafana-svc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/heapster/influxdb-svc.yaml",
			constants.AddonsPath,
			"influxdb-svc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/heapster/heapster-rc.yaml",
			constants.AddonsPath,
			"heapster-rc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/heapster/heapster-svc.yaml",
			constants.AddonsPath,
			"heapster-svc.yaml",
			"0640"),
	}, false, "heapster"),
	"ingress": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/ingress/ingress-configmap.yaml",
			constants.AddonsPath,
			"ingress-configmap.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/ingress/ingress-rc.yaml",
			constants.AddonsPath,
			"ingress-rc.yaml",
			"0640"),
		NewMemoryAsset(
			"deploy/addons/ingress/ingress-svc.yaml",
			constants.AddonsPath,
			"ingress-svc.yaml",
			"0640"),
	}, false, "ingress"),
	"awsecr-creds": NewAddon([]*MemoryAsset{
		NewMemoryAsset(
			"deploy/addons/awsecr-creds/awsecr-creds-rc.yaml",
			constants.AddonsPath,
			"awsecr-creds-rc.yaml",
			"0640"),
	}, false, "awsecr-creds"),
}

Functions

func AddMinikubeAddonsDirToAssets

func AddMinikubeAddonsDirToAssets(assetList *[]CopyableFile)

Types

type Addon

type Addon struct {
	Assets []*MemoryAsset
	// contains filtered or unexported fields
}

func NewAddon

func NewAddon(assets []*MemoryAsset, enabled bool, addonName string) *Addon

func (*Addon) IsEnabled

func (a *Addon) IsEnabled() (bool, error)

type BaseAsset

type BaseAsset struct {
	Length      int
	AssetName   string
	TargetDir   string
	TargetName  string
	Permissions string
	// contains filtered or unexported fields
}

func (*BaseAsset) GetAssetName

func (b *BaseAsset) GetAssetName() string

func (*BaseAsset) GetPermissions

func (b *BaseAsset) GetPermissions() string

func (*BaseAsset) GetTargetDir

func (b *BaseAsset) GetTargetDir() string

func (*BaseAsset) GetTargetName

func (b *BaseAsset) GetTargetName() string

type CopyableFile

type CopyableFile interface {
	io.Reader
	GetLength() int
	GetAssetName() string
	GetTargetDir() string
	GetTargetName() string
	GetPermissions() string
}

type FileAsset

type FileAsset struct {
	BaseAsset
}

func NewFileAsset

func NewFileAsset(assetName, targetDir, targetName, permissions string) (*FileAsset, error)

func (*FileAsset) GetLength

func (f *FileAsset) GetLength() int

func (*FileAsset) Read

func (f *FileAsset) Read(p []byte) (int, error)

type MemoryAsset

type MemoryAsset struct {
	BaseAsset
}

func NewMemoryAsset

func NewMemoryAsset(assetName, targetDir, targetName, permissions string) *MemoryAsset

func (*MemoryAsset) GetLength

func (m *MemoryAsset) GetLength() int

func (*MemoryAsset) Read

func (m *MemoryAsset) Read(p []byte) (int, error)

Jump to

Keyboard shortcuts

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