Compare commits

...

2 Commits

Author SHA1 Message Date
Florent BEAUCHAMP
6fdf0a97e4 Simplify @xen-orchestra/backups/_runners/_writers/IncrementalRemoteWriter.mjs
Co-authored-by: Julien Fontanet <julien.fontanet@isonoe.net>
2024-02-14 07:46:39 +01:00
Florent Beauchamp
3a4bdd3b1e fix(backups): ensure vhd are chained with older vhd 2024-02-13 12:31:22 +00:00
2 changed files with 6 additions and 2 deletions

View File

@@ -7,7 +7,7 @@ import { chainVhd, checkVhdChain, openVhd, VhdAbstract } from 'vhd-lib'
import { createLogger } from '@xen-orchestra/log'
import { decorateClass } from '@vates/decorate-with'
import { defer } from 'golike-defer'
import { dirname } from 'node:path'
import { dirname, basename as pathBasename } from 'node:path'
import { formatFilenameDate } from '../../_filenameDate.mjs'
import { getOldEntries } from '../../_getOldEntries.mjs'
@@ -199,7 +199,10 @@ export class IncrementalRemoteWriter extends MixinRemoteWriter(AbstractIncrement
undefined,
`missing parent of ${id} in ${dirname(path)}, looking for ${vdi.other_config[TAG_BASE_DELTA]}`
)
assert.ok(
pathBasename(parentPath) < pathBasename(path),
`vhd must be sorted to be chained`
)
parentPath = parentPath.slice(1) // remove leading slash
// TODO remove when this has been done before the export

View File

@@ -33,6 +33,7 @@
<!--packages-start-->
- @xen-orchestra/backups patch
- xo-server patch
- xo-server-audit patch
- xo-web patch