Skip to content

client

local client = require("@rodeo-client-lune/client")
EntryDescription
BackendInfo
ConnectOpts
ProcessInfo
RodeoClient

type BackendInfo = { id: string, kind: string, name: string }

type ConnectOpts = {
host: string?,
port: number,
rodeoBin: string?,
-- Max time to wait for the server to come up. Default 30000ms.
readyTimeoutMs: number?,
-- Poll interval while waiting for the server. Default 200ms.
readyPollMs: number?,
}

type ProcessInfo = { [string]: any }

type RodeoClient = {
getState: () -> StateSnapshot,
listProcesses: () -> { ProcessInfo },
kill: (processId: number) -> (),
listBackends: (kind: string?) -> { BackendInfo },
getLocalStudio: () -> studioMod.StudioBackend,
getStudio: (idOrName: string) -> studioMod.StudioBackend,
getVms: () -> { vmMod.Vm },
getVm: (vmId: string) -> vmMod.Vm,
close: () -> (),
}