/api/servers.json
a GET to the address will return a JSON object like
{ "version": "1.0.0", "success": true, "status_ok": true, "servers": [ { "name": "server_name", "karabo_name": "server/name", "status": "up, running", "since": "calendar date", "duration": uptime_in_seconds }, ... more servers ] }
/api/servers/:server_name:.json
a GET to the address will return a JSON object like
{ "version": "1.0.0", "success": true, "status_ok": true, "servers": [ { "name": "server_name", "karabo_name": "server/name", "status": "up, running", "since": "calendar date", "duration": uptime_in_seconds }, ] }
a PUT to the address with a JSON object like
{ "server": { "command": "command_name", }, }
will instruct the daemontools supervisor to execute the command command_name. The following commands are allowed:
up: If the service is not running, start it. If the service stops, restart it.
down: If the service is running, send it a TERM signal and then a CONT signal. After it stops, do not restart it.
once: If the service is not running, start it. Do not restart it if it stops.
kill: Send a KILL signal to the service and to the service's whole process group.
Note: the name field is optional