Dominevo
ReferenceDevice capabilities

workload

── The capability ───────────────────────────────────────────────────

── The capability ───────────────────────────────────────────────────

At a glance

Capabilityworkload
Provided byThe device's own driver provides it: each device registers its own provider.
Active providers per deviceone
Device typesworkload
Device rolesworkload: vm, app-container, lxc, app, host
Sourcepackages/types/src/capabilities/workload.cap.ts

Methods

Every method takes the device id (deviceId) to address the device; the input tables below list the other fields.

MethodKindRequired of a providerAccess
startmutationnoprotected
stopmutationnoprotected
restartmutationnoprotected
pausemutationnoprotected
resumemutationnoprotected
forceStopmutationnoadmin
getOptionsqueryyesprotected

start

mutation · optional for a provider

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.startStartstate = "running"

stop

mutation · optional for a provider

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.stopStopstate = "stopped"

restart

mutation · optional for a provider

Same tier as start / stop and the switch they derive: a restart is a stop and a start.

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.restartRestart

pause

mutation · optional for a provider

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.pausePausestate = "paused"

resume

mutation · optional for a provider

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.resumeResumestate = "running"

forceStop

mutation · optional for a provider

Admin: a force stop skips the orderly shutdown and can lose data.

Input

No fields besides deviceId.

Output

Nothing.

Actions (offered in automations and on device cards)

ActionLabelSets
workload.forceStopForce stopstate = "stopped"

getOptions

query

What THIS device can do, probed — the UI is derived from it.

Input

No fields besides deviceId.

Output

What this device can do, probed by its provider: a flag is true only when the platform really serves it for THIS device.

FieldTypeRequiredDescription
supportsStartbooleanyes
supportsStopbooleanyes
supportsRestartbooleanyes
supportsPausebooleanyesPause AND resume.
supportsForceStopbooleanyes
hasResourcesbooleanyes
hasPortsbooleanyes
hasAddressesbooleanyes
hasAutostartbooleanyes
hasUpdateCheckbooleanyes

Runtime state

The state Dominevo keeps for each device with this capability, readable without calling the provider.

FieldTypeRequiredDescription
state"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed" | nullyesnull = unknown, never stopped.
sincenumber | nullyesEpoch ms the current state began (uptime while running); null when unknown.
hostDeviceIdnumber | nullyesThe host device this runs on, when the provider has adopted it.
imagestring | nullyesThe image a container runs (nginx:1.27).
osstring | nullyesThe operating system (a VM, an LXC, a host).
versionstring | nullyesThe version or firmware it runs.
autostartboolean | nullyesStarts with its host; null when the platform does not say.
resources{ cpuPercent: number | null; memoryUsedBytes: number | null; memoryPercent?: number | null; memoryLimitBytes: number | null; vcpus: number | null; diskUsedBytes: number | null; diskTotalBytes: number | null; netRxKbps: n…yes
ports({ port: number; hostPort: number | null; hostIp: string | null; protocol: "tcp" | "udp" })[]yes
addressesstring[]yesThe addresses it is reachable on (IPs or host names).
updateAvailableboolean | nullyesA newer image / version exists. Installing it stays the update cap.
lastFetchedAtnumberyes

Events

onStarted

FieldTypeRequiredDescription
deviceIdnumberyes
state"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
previous"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
sincenumber | nullyes

onStopped

FieldTypeRequiredDescription
deviceIdnumberyes
state"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
previous"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
sincenumber | nullyes

onCrashed

FieldTypeRequiredDescription
deviceIdnumberyes
state"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
previous"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
sincenumber | nullyes

onRecovered

FieldTypeRequiredDescription
deviceIdnumberyes
state"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
previous"running" | "paused" | "stopped" | "starting" | "stopping" | "crashed"yes
sincenumber | nullyes