zadmin/docs/topics.md
2025-04-06 17:23:07 +02:00

907 B

NATS Topics

<ID> is the id of the client; this is different for each host in the inventory.

Sent to the server

Events

s.<ID>.event
Can be any event sent by the client:

  • Structure:

    • event: event
    • event_meta: event specific data
      • restart_reason: updates
  • Possible events:

    • dev_hello # sent by client periodically to show sign of life
    • dev_online # client is online
    • dev_powerdown # client is shutting down
    • agent_stop # agent is restarting

s.<ID>.stats

Sent to client

Tasks

c.<ID>.task

Common tasks for the client to perform:
  • restarts
  • poweroff
  • send screenshot to server

Control Commands

c.<ID>.control.command
  • Sent by the server
  • Should be run by the client
  • Arbitrary shell command entered by admin
  • Should return data such as exit code, command output, duration, etc.