Merge pull request #139 from jkaninda/refactor

fix: fix s3 remote path when backing up multiple databases
This commit is contained in:
2024-12-07 02:11:34 +01:00
committed by GitHub

View File

@@ -58,7 +58,7 @@ func s3Backup(db *dbConfig, config *BackupConfig) {
Region: awsConfig.region, Region: awsConfig.region,
DisableSsl: awsConfig.disableSsl, DisableSsl: awsConfig.disableSsl,
ForcePathStyle: awsConfig.forcePathStyle, ForcePathStyle: awsConfig.forcePathStyle,
RemotePath: awsConfig.remotePath, RemotePath: config.remotePath,
LocalPath: tmpPath, LocalPath: tmpPath,
}) })
if err != nil { if err != nil {
@@ -119,7 +119,7 @@ func s3Restore(db *dbConfig, conf *RestoreConfig) {
Region: awsConfig.region, Region: awsConfig.region,
DisableSsl: awsConfig.disableSsl, DisableSsl: awsConfig.disableSsl,
ForcePathStyle: awsConfig.forcePathStyle, ForcePathStyle: awsConfig.forcePathStyle,
RemotePath: awsConfig.remotePath, RemotePath: conf.remotePath,
LocalPath: tmpPath, LocalPath: tmpPath,
}) })
if err != nil { if err != nil {