mirror of
https://github.com/immich-app/immich.git
synced 2024-12-28 06:31:58 +00:00
fix(server): database backups compatible with deduplication (#13965)
gzip --rsyncable has a slightly worse compression ratio, but allows for efficient deduplication and, as the name implies, faster rsync operations. Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
This commit is contained in:
parent
f4741c70f3
commit
564449a555
1 changed files with 2 additions and 1 deletions
|
@ -97,7 +97,8 @@ export class BackupService extends BaseService {
|
|||
env: { PATH: process.env.PATH, PGPASSWORD: isUrlConnection ? undefined : config.password },
|
||||
});
|
||||
|
||||
const gzip = this.processRepository.spawn(`gzip`, []);
|
||||
// NOTE: `--rsyncable` is only supported in GNU gzip
|
||||
const gzip = this.processRepository.spawn(`gzip`, ['--rsyncable']);
|
||||
pgdump.stdout.pipe(gzip.stdin);
|
||||
|
||||
const fileStream = this.storageRepository.createWriteStream(backupFilePath);
|
||||
|
|
Loading…
Reference in a new issue