config

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2017 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	HostfoldersDefaultPath  = "/mnt/sda1"
	HostfoldersMountPathKey = "hostfolders-mountpath"
)

Variables

This section is empty.

Functions

func GetHostfoldersMountPath

func GetHostfoldersMountPath(name string) string

func IsPositive added in v1.5.0

func IsPositive(name string, val string) error

func IsValidCIDR added in v1.5.0

func IsValidCIDR(name string, cidr string) error

func IsValidDiskSize added in v1.5.0

func IsValidDiskSize(name string, diskSize string) error

func IsValidDriver added in v1.5.0

func IsValidDriver(string, driver string) error

func IsValidMemorySize added in v1.5.0

func IsValidMemorySize(name string, memorySize string) error

func IsValidPath added in v1.5.0

func IsValidPath(name string, path string) error

func IsValidProxy added in v1.5.0

func IsValidProxy(name string, uri string) error

func IsValidUrl added in v1.5.0

func IsValidUrl(_ string, isoURL string) error

Types

type GlobalConfigType

type GlobalConfigType struct {
	FilePath string `json:"-"`

	HostFolders   []HostFolder
	ActiveProfile string
}
var AllInstancesConfig *GlobalConfigType

func NewAllInstancesConfig

func NewAllInstancesConfig(path string) (*GlobalConfigType, error)

Create new object with data if file exists or Create json file and return object if doesn't exists

func (*GlobalConfigType) Delete

func (cfg *GlobalConfigType) Delete() error

func (*GlobalConfigType) Write

func (cfg *GlobalConfigType) Write() error

type HostFolder

type HostFolder struct {
	Name    string
	Type    string
	Options map[string]string
}

func (*HostFolder) Mountpoint

func (hf *HostFolder) Mountpoint() string

type InstanceConfigType

type InstanceConfigType struct {
	FilePath     string `json:"-"`
	OcPath       string
	IsRegistered bool

	HostFolders []HostFolder
}
var InstanceConfig *InstanceConfigType

func NewInstanceConfig

func NewInstanceConfig(path string) (*InstanceConfigType, error)

Create new object with data if file exists or Create json file and return object if doesn't exists

func (*InstanceConfigType) Delete

func (cfg *InstanceConfigType) Delete() error

func (*InstanceConfigType) Write

func (cfg *InstanceConfigType) Write() error

type MinishiftDirs added in v1.6.0

type MinishiftDirs struct {
	Home       string
	Config     string
	Machines   string
	Certs      string
	Cache      string
	IsoCache   string
	OcCache    string
	ImageCache string
	Addons     string
	Logs       string
	Tmp        string
}
var InstanceDirs *MinishiftDirs

func NewMinishiftDirs added in v1.6.0

func NewMinishiftDirs() *MinishiftDirs

Constructor for MinishiftDirs

Jump to

Keyboard shortcuts

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