mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Update to keep older logs
This commit is contained in:
@@ -1393,11 +1393,14 @@ class Builds extends Action
|
||||
$durationEnd = \microtime(true);
|
||||
$buildDuration = (int) \ceil($durationEnd - $durationStart);
|
||||
|
||||
$existingLogs = $deployment->getAttribute('buildLogs', '');
|
||||
$buildLogs = empty($existingLogs) ? $message : $existingLogs . "\n" . $message;
|
||||
|
||||
$deployment = $dbForProject->updateDocument('deployments', $deploymentId, new Document([
|
||||
'buildEndedAt' => $endTime,
|
||||
'buildDuration' => $buildDuration,
|
||||
'status' => 'failed',
|
||||
'buildLogs' => $message,
|
||||
'buildLogs' => $buildLogs,
|
||||
]));
|
||||
|
||||
if ($deployment->getSequence() === $resource->getAttribute('latestDeploymentInternalId', '')) {
|
||||
|
||||
Reference in New Issue
Block a user