Restore one container's appdata
POST/appdata/backup/restore
Required role: admin. Only an account or token with the admin role can call this operation.
curl --request POST \
--header "Authorization: Bearer $HOSERVA_TOKEN" \
--header "Content-Type: application/json" \
--data @body.json \
"https://$HOSERVA_HOST:8008/api/v1/appdata/backup/restore"
Queues an appdata_restore job (service class). The archive is fetched, decrypted and verified before anything is changed. Then the container is stopped if it is running, a snapshot of its current appdata is written to the enabled backup destinations, and only when that snapshot is written is the appdata replaced by the archive's content; if the snapshot cannot be written the live appdata is not touched. The container is started again afterwards. Requires confirm: true: the restore overwrites the container's appdata (400 confirmation_required otherwise). 404 archive_not_found for an archive the named destination does not hold, and 409 array_stopped while the array is stopped or its storage is not ready.
Request
Responses
- 200
- default
The queued or running appdata restore job.
An error response.