fedops

package
v0.0.0-...-a8514d4 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2015 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DigitalOcean   uint = 0
	AWS            uint = 1
	GoogleCloud    uint = 2
	MicrosoftAzure uint = 3
	OpenStack      uint = 4

	SaltSize int = 512

	ClusterIDSize   int = 32
	WarehouseIDSize int = 16
	TruckIDSize     int = 16
	ContainerIDSize int = 16

	AuthorizationCost int = 10

	FedopsRemoteKeySize int = 32

	FedopsPoolTime     time.Duration = 5
	FedopsBootWaitTime time.Duration = 30

	FedopsError   uint = 0
	FedopsOk      uint = 1
	FedopsUnknown uint = 2

	FedopsTypeTruck     uint = 0
	FedopsTypeWarehouse uint = 1

	FedopsRepo     string = "github.com/wmiller848/Fedops"
	ConfigFileName string = "Fedops"
)

Variables

This section is empty.

Functions

func GetConfigFile

func GetConfigFile(pwd string) ([]byte, error)

func GetSalt

func GetSalt(pwd string) ([]byte, error)

func HasConfigFile

func HasConfigFile(pwd string) bool

Types

type Dispatcher

type Dispatcher struct {
	Cipherkey      []byte
	Salt           []byte
	Version        string
	PowerDirectory string
	Timeout        time.Duration
	Config         DispatcherConfig
}

func CreateDispatcher

func CreateDispatcher(key []byte, pwd string, session bool) (*Dispatcher, error)

func (*Dispatcher) CreateContainer

func (d *Dispatcher) CreateContainer(promise chan FedopsAction, repo string)

func (*Dispatcher) CreateTruck

func (d *Dispatcher) CreateTruck(promise chan FedopsAction, provider, memSize, diskSize, numVcpus string)

func (*Dispatcher) CreateWarehouse

func (d *Dispatcher) CreateWarehouse(promise chan FedopsAction, providerName, memSize, diskSize, numVcpus string)

func (*Dispatcher) DestroyContainer

func (d *Dispatcher) DestroyContainer(promise chan FedopsAction, containerID string)

func (*Dispatcher) DestroyTruck

func (d *Dispatcher) DestroyTruck(promise chan FedopsAction, truckID string)

func (*Dispatcher) DestroyWarehouse

func (d *Dispatcher) DestroyWarehouse(promise chan FedopsAction, warehouseID string)

func (*Dispatcher) Info

func (d *Dispatcher) Info()

func (*Dispatcher) InitCloudProvider

func (d *Dispatcher) InitCloudProvider(promise chan FedopsAction, provider string, tokens Tokens)

func (*Dispatcher) OpenConnection

func (d *Dispatcher) OpenConnection(vmIP string) *tls.Conn

func (*Dispatcher) Refresh

func (d *Dispatcher) Refresh(promise chan FedopsAction)

func (*Dispatcher) SSH

func (d *Dispatcher) SSH(vmID string) uint

func (*Dispatcher) ShipContainerImageToTruck

func (d *Dispatcher) ShipContainerImageToTruck(promise chan FedopsAction, containerID, truckID string)

func (*Dispatcher) ShipContainerToWarehouse

func (d *Dispatcher) ShipContainerToWarehouse(promise chan FedopsAction, containerID, warehouseID string)

func (*Dispatcher) Unload

func (d *Dispatcher) Unload() bool

func (*Dispatcher) WriteToConn

func (d *Dispatcher) WriteToConn(conn *tls.Conn, req *fedops_network.FedopsRequest) error

type DispatcherConfig

type DispatcherConfig struct {
	ClusterID  string
	Created    string
	Modified   string
	Certs      []fedops_encryption.Cert
	SSHKeys    []fedops_provider.ProviderKeypair
	Tokens     map[string]Tokens
	Warehouses map[string]*fedops_warehouse.Warehouse
	Trucks     map[string]*fedops_truck.Truck
	Containers map[string]*fedops_container.Container
}

This config is stored encrypted on disk

type DispatcherError

type DispatcherError struct {
	// contains filtered or unexported fields
}

func (*DispatcherError) Error

func (err *DispatcherError) Error() string

type FedopsAction

type FedopsAction struct {
	Status uint
}

type Tokens

type Tokens struct {
	AccessToken   string
	SecurityToken string
}

Jump to

Keyboard shortcuts

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