This commit is contained in:
seb
2026-10-14 00:08:11 +02:00
parent 11f6a8fc0f
commit 74b24686bc
14 changed files with 962 additions and 12 deletions

View File

@@ -18,6 +18,7 @@ import { getOrCreateCert } from '../util/cert.js';
import { createLogger } from '../util/logger.js';
import v1Router from '../v1/index.js';
import { startBackendMonitor, stopBackendMonitor, isDevMode } from '../backendmonitor/server.js';
import { startBackupService, stopBackupService } from '../services/backupService.js';
const apiLog = createLogger('api');
@@ -245,6 +246,12 @@ export async function startApi() {
}
}
try {
startBackupService();
} catch (err) {
apiLog.error('Failed to start Backup Service:', err.message);
}
return server;
})();
@@ -267,6 +274,7 @@ export async function stopApi() {
await shutdownImageCropWorkers();
// Same for the pooled sandbox threads that run `javascript_execute` / applets.
await shutdownJavascriptSandboxWorkers();
await stopBackupService();
const closers = [];
if (server) {
const s = server;