[autofix.ci] apply automated fixes

This commit is contained in:
autofix-ci[bot]
2025-11-04 10:38:15 +00:00
committed by GitHub
parent dcdbed047b
commit d6704dbd27
6 changed files with 30 additions and 6 deletions

View File

@@ -19,7 +19,11 @@ export const runComposeBackup = async (
const project = await findProjectById(environment.projectId);
const { prefix, databaseType } = backup;
const destination = backup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${timestamp}.sql.gz`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
const deployment = await createDeploymentBackup({

View File

@@ -19,7 +19,11 @@ export const runMariadbBackup = async (
const project = await findProjectById(environment.projectId);
const { prefix } = backup;
const destination = backup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${timestamp}.sql.gz`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
const deployment = await createDeploymentBackup({

View File

@@ -16,7 +16,11 @@ export const runMongoBackup = async (mongo: Mongo, backup: BackupSchedule) => {
const project = await findProjectById(environment.projectId);
const { prefix } = backup;
const destination = backup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${timestamp}.sql.gz`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
const deployment = await createDeploymentBackup({

View File

@@ -16,7 +16,11 @@ export const runMySqlBackup = async (mysql: MySql, backup: BackupSchedule) => {
const project = await findProjectById(environment.projectId);
const { prefix } = backup;
const destination = backup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${timestamp}.sql.gz`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
const deployment = await createDeploymentBackup({

View File

@@ -25,7 +25,11 @@ export const runPostgresBackup = async (
});
const { prefix } = backup;
const destination = backup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${timestamp}.sql.gz`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
try {

View File

@@ -12,7 +12,11 @@ export const backupVolume = async (
volumeBackup.application?.serverId || volumeBackup.compose?.serverId;
const { VOLUME_BACKUPS_PATH } = paths(!!serverId);
const destination = volumeBackup.destination;
const timestamp = new Date().toISOString().replace('T', '_').replace(/:/g, '-').replace('.', '_');
const timestamp = new Date()
.toISOString()
.replace("T", "_")
.replace(/:/g, "-")
.replace(".", "_");
const backupFileName = `${volumeName}-${timestamp}.tar`;
const bucketDestination = `${normalizeS3Path(prefix)}${backupFileName}`;
const rcloneFlags = getS3Credentials(volumeBackup.destination);