Versions in this module Expand all Collapse all v1 v1.2.1 Apr 29, 2021 v1.2.0 Apr 20, 2021 Changes in this version + const AnkaStatusError + const AnkaStatusFail + const AnkaStatusOK + func CMDExecWrapper(cmd *exec.Cmd, output *bytes.Buffer) error + type AnkaCLI struct + func NewAnkaCLI(executor CommandExecutor) *AnkaCLI + func (ac *AnkaCLI) ActivateLicense(licenseKey string) error + func (ac *AnkaCLI) EnsureAnkaBin() error + func (ac *AnkaCLI) Exec(vmID string, command []string) error + func (ac *AnkaCLI) PullImage(vmTemplateID string) error + func (ac *AnkaCLI) Show(vmID string) (VMShowOutput, error) + func (ac *AnkaCLI) Start(vmId string) (VMStartOutput, error) + func (ac *AnkaCLI) Stop(vmId string) (VMStopOutput, error) + func (ac *AnkaCLI) ValidateLicense() error + type AnkaRegistryClient struct + func NewAnkaRegistryClient() *AnkaRegistryClient + func (cc *AnkaRegistryClient) GetVMTemplate(vmTemplateUrl string) (string, error) + type CommandExecutor func(cmd *exec.Cmd, output *bytes.Buffer) error + type DeleteVMBody struct + VMID string + type MacRuntime struct + UnitsVMIDs *sync.Map + func NewMacRuntime(registryClient RegistryClient) *MacRuntime + func (m *MacRuntime) ContainerStatus(unitName, unitImage string) (*api.UnitStatus, error) + func (m *MacRuntime) CreateContainer(unit api.Unit, spec *api.PodSpec, podName string, ...) (*api.UnitStatus, error) + func (m *MacRuntime) GetLogBuffer(options runtime.LogOptions) (*logbuf.LogBuffer, error) + func (m *MacRuntime) GetPid(unitName string) (int, bool) + func (m *MacRuntime) RemoveContainer(unit *api.Unit) error + func (m *MacRuntime) RemovePodSandbox(spec *api.PodSpec) error + func (m *MacRuntime) RunPodSandbox(spec *api.PodSpec) error + func (m *MacRuntime) SetPodNetwork(netNS, podIP string) + func (m *MacRuntime) StartContainer(unit api.Unit, spec *api.PodSpec, podName string) (*api.UnitStatus, error) + func (m *MacRuntime) StopPodSandbox(spec *api.PodSpec) error + func (m *MacRuntime) UnitRunning(unitName string) bool + type RegistryClient interface + GetVMTemplate func(vmTemplateID string) (string, error) + type StartVMBody struct + CPU int + Count int + Metadata map[string]string + Name string + NameTemplate string + NodeID string + RAM int + Tag string + VMID string + type StartVMResp struct + IDs []string + type VMCreateOutput struct + Body VMInfoBase + type VMInfo struct + CpuCores int + IP string + NodeID string + Status string + type VMInfoBase struct + UUID string + type VMPullOutput struct + type VMRespBase struct + Message string + Status string + type VMRunOutput struct + type VMShowBody struct + CPUCores int + CPUFrequency int + CPUHtt bool + CreationDate string + Encrypted bool + FrameBuffers int + HardDrive int + ImageSize int + Name string + RAM string + RAMSize int + Status string + StopDate string + type VMShowOutput struct + Body VMShowBody + type VMStartOutput struct + Body VMShowBody + type VMStatusBody struct + Progress int + VMInfo VMInfo + type VMStatusEmptyResp struct + Body []string + type VMStatusResp struct + Body VMStatusBody + type VMStopOutput struct