mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-08 17:18:48 +00:00
Fix backup-all script (#8255)
Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
parent
2ff661d172
commit
d3ffb3c2fd
@ -1010,7 +1010,9 @@ export function devTool (
|
||||
|
||||
const skipWorkspaces = new Set(cmd.skip.split(',').map((it) => it.trim()))
|
||||
|
||||
const token = generateToken(systemAccountUuid, '' as WorkspaceUuid)
|
||||
const token = generateToken(systemAccountUuid, '' as WorkspaceUuid, {
|
||||
service: 'tool'
|
||||
})
|
||||
const workspaces = (await getAccountClient(token).listWorkspaces(cmd.region))
|
||||
.sort((a, b) => {
|
||||
const bsize = b.backupInfo?.backupSize ?? 0
|
||||
|
@ -2810,6 +2810,13 @@ export async function checkBackupIntegrity (ctx: MeasureContext, storage: Backup
|
||||
modified = true
|
||||
}
|
||||
}
|
||||
if (backupInfo.migrations == null) {
|
||||
backupInfo.migrations = {}
|
||||
}
|
||||
if (!backupInfo.migrations.zeroCheckSize) {
|
||||
backupInfo.migrations.zeroCheckSize = true
|
||||
modified = true
|
||||
}
|
||||
if (modified) {
|
||||
await storage.writeFile(infoFile, gzipSync(JSON.stringify(backupInfo, undefined, 2), { level: defaultLevel }))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user