Trigger daemon update for a node
const url = 'https://opfield.example.com/api/system/daemon-updates/550e8400-e29b-41d4-a716-446655440000';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"now":true}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://opfield.example.com/api/system/daemon-updates/550e8400-e29b-41d4-a716-446655440000 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "now": true }'Updates the daemon of a node to the latest release. While backups, image builds, Docker migrations, image pulls, container actions, storage copies, or container archive transfers run on the node, the update waits for them first: waitingForTasks in the response, metadata.updatePhase: waiting_for_tasks and metadata.updateWaitingForTasks on the node. After 30 minutes it goes ahead anyway and keeps a warning in metadata.lastUpdate.warnings. Nodes in a lease-mode Availability policy then wait for their peers (leaseSequenced). now: true waits for neither and ends the wait of an update already waiting (waitSkipped); skipping the peers is kept as a warning in metadata.lastUpdate.warnings. An update of a Docker or nginx node whose daemon advertises daemon_stream_handover_v1 keeps its relay stream sessions; metadata.lastUpdate.connections holds what the update kept and cut, and metadata.lastUpdate.serviceRestart says when the update restarted the whole service once for a newer launcher (or why not).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Example
550e8400-e29b-41d4-a716-446655440000Request Body
Section titled “Request Body”Optional: { "now": true } to update without waiting for running tasks or lease peers
object
Update without waiting for the long tasks running on the node (they may fail) or for its lease peers. Also ends the wait of an update that already waits for them.
Examplegenerated
{ "now": true}Responses
Section titled “Responses”Successful response
object
Resource object. Exact fields depend on the endpoint.
object
Example
{ "data": { "currentVersion": "1.2.3", "latestVersion": "1.2.4", "updateAvailable": true }}Bad request
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "VALIDATION_ERROR", "message": "Request validation failed", "details": [ { "path": [ "name" ], "message": "Required" } ]}Authentication required
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "UNAUTHORIZED", "message": "Authentication required"}Forbidden
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "FORBIDDEN", "message": "Insufficient permissions"}Not found
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "NOT_FOUND", "message": "Resource not found"}Conflict
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "CONFLICT", "message": "Resource already exists"}Unprocessable entity
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "UNPROCESSABLE_ENTITY", "message": "Request could not be processed"}Internal server error
object
Error code
Human-readable error message
Additional error details
Example
{ "code": "INTERNAL_ERROR", "message": "Internal server error"}