bootstrap

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2017 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FsMagicAUFS = 0x61756673 // https://goo.gl/CBwx43
	FsMagicZFS  = 0x2FC12FC1 // https://goo.gl/xTvzO5
)
View Source
const LoopbackNetConf string = `
{
    "cniVersion": "0.2.0",
    "type": "loopback"
}`
View Source
const LoopbackNetPath string = "/etc/cni/net.d/10-loopback.conf"
View Source
const NspawnNetConf string = `` /* 297-byte string literal not displayed */
View Source
const NspawnNetPath string = "/etc/cni/net.d/10-kube-spawn-net.conf"

Variables

This section is empty.

Functions

func CreateSharedTmpdir

func CreateSharedTmpdir()

func Download

func Download(url, fpath string) (*os.File, error)

func DownloadK8sBins

func DownloadK8sBins(version, dir string) error

func DownloadSocatBin

func DownloadSocatBin(dir string) error

func EnlargeStoragePool

func EnlargeStoragePool(poolSize int64) error

func EnsureBridge

func EnsureBridge() error

func EnsureRequirements

func EnsureRequirements()

func Exec

func Exec(stdin io.Reader, stdout, stderr io.Writer, machine string, cmd ...string) error

func ExecQuiet

func ExecQuiet(machine string, cmd ...string) error

func GetIPAddressLegacy

func GetIPAddressLegacy(mach string) (string, error)

func GetNodeName

func GetNodeName(no int) string

func GetPoolSize

func GetPoolSize(baseImage string, nodes int) (int64, error)

func IsNodeRunning

func IsNodeRunning(nodeName string) bool

func MachineImageExists

func MachineImageExists(machine string) bool

func NewNode

func NewNode(baseImage, machine string) error

func PathSupportsOverlay

func PathSupportsOverlay(path string) error

PathSupportsOverlay checks whether the given path is compatible with OverlayFS. This method also calls isOverlayfsAvailable(). It returns error if OverlayFS is not supported.

func WriteNetConf

func WriteNetConf() error

Types

type Node

type Node struct {
	Name string
	IP   string
}

func GetRunningNodes

func GetRunningNodes() ([]Node, error)

Jump to

Keyboard shortcuts

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