manager

package
v1.3.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KubeAPIServerService         = "kube-apiserver"
	KubeSchedulerService         = "kube-scheduler"
	KubeControllerManagerService = "kube-controller-manager"
)
View Source
const (
	ETCDService    = "etcd"
	KubeletService = "kubelet"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	VMManager
}

Manager to manager fault trigger

func NewManager

func NewManager(vmManagerName string) *Manager

NewManager returns a manager instance

func (*Manager) StartETCD

func (m *Manager) StartETCD() error

StartETCD starts the etcd service

func (*Manager) StartKubeAPIServer

func (m *Manager) StartKubeAPIServer() error

StartKubeAPIServer starts the apiserver

func (*Manager) StartKubeControllerManager

func (m *Manager) StartKubeControllerManager() error

StartKubeControllerManager starts the kube-controller-manager service

func (*Manager) StartKubeScheduler

func (m *Manager) StartKubeScheduler() error

StartKubeScheduler starts the kube-scheduler service

func (*Manager) StartKubelet

func (m *Manager) StartKubelet() error

StartKubelet starts the kubelet service

func (*Manager) StopETCD

func (m *Manager) StopETCD() error

StopETCD stops the etcd service

func (*Manager) StopKubeAPIServer

func (m *Manager) StopKubeAPIServer() error

StopKubeAPIServer stops the apiserver

func (*Manager) StopKubeControllerManager

func (m *Manager) StopKubeControllerManager() error

StopKubeControllerManager stops the kube-controller-manager service

func (*Manager) StopKubeScheduler

func (m *Manager) StopKubeScheduler() error

StopKubeScheduler stops the kube-scheduler service

func (*Manager) StopKubelet

func (m *Manager) StopKubelet() error

StopKubelet stops the kubelet service

type QMVMManager added in v1.0.2

type QMVMManager struct {
}

func (*QMVMManager) ListVMs added in v1.0.2

func (qm *QMVMManager) ListVMs() ([]*VM, error)

func (*QMVMManager) Name added in v1.0.2

func (qm *QMVMManager) Name() string

func (*QMVMManager) StartVM added in v1.0.2

func (qm *QMVMManager) StartVM(vm *VM) error

func (*QMVMManager) StopVM added in v1.0.2

func (qm *QMVMManager) StopVM(vm *VM) error

type VM

type VM struct {
	Host   string   `json:"host"`
	Port   int64    `json:"port"`
	Name   string   `json:"name"`
	Role   []string `json:"role"`
	Status string   `json:"status"`
}

VM defines the descriptive information of a virtual machine

func (*VM) Verify

func (v *VM) Verify() error

type VMManager added in v1.0.2

type VMManager interface {
	Name() string
	ListVMs() ([]*VM, error)
	StopVM(*VM) error
	StartVM(*VM) error
}

type VirshVMManager added in v1.0.2

type VirshVMManager struct {
}

func (*VirshVMManager) ListVMs added in v1.0.2

func (m *VirshVMManager) ListVMs() ([]*VM, error)

ListVMs lists vms

func (*VirshVMManager) Name added in v1.0.2

func (m *VirshVMManager) Name() string

func (*VirshVMManager) StartVM added in v1.0.2

func (m *VirshVMManager) StartVM(v *VM) error

StartVM starts vm

func (*VirshVMManager) StopVM added in v1.0.2

func (m *VirshVMManager) StopVM(v *VM) error

StopVM stops vm

Jump to

Keyboard shortcuts

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