diff --git a/app/server/jobs/healthchecks.ts b/app/server/jobs/healthchecks.ts index e67f0f3d..83d253c2 100644 --- a/app/server/jobs/healthchecks.ts +++ b/app/server/jobs/healthchecks.ts @@ -15,12 +15,16 @@ export class VolumeHealthCheckJob extends Job { }); for (const volume of volumes) { - await withContext({ organizationId: volume.organizationId }, async () => { - const { status } = await volumeService.checkHealth(volume.shortId); - if (status === "error" && volume.autoRemount) { - await volumeService.mountVolume(volume.shortId); - } - }); + try { + await withContext({ organizationId: volume.organizationId }, async () => { + const { status } = await volumeService.checkHealth(volume.shortId); + if (status === "error" && volume.autoRemount) { + await volumeService.mountVolume(volume.shortId); + } + }); + } catch (error) { + logger.error(`Health check failed for volume ${volume.name}:`, error); + } } return { done: true, timestamp: new Date() };