fix: Fix AWS S3 and SSH backup in scheduled mode on Docker and Docker Swarm

This commit is contained in:
2024-08-04 11:19:11 +02:00
parent df2757fb1d
commit 012f6392a7
9 changed files with 67 additions and 32 deletions

View File

@@ -55,4 +55,5 @@ func Fatal(msg string, args ...any) {
fmt.Printf("%s ERROR: %s\n", currentTime, formattedMessage)
}
os.Exit(1)
os.Kill.Signal()
}

View File

@@ -24,8 +24,6 @@ func CreateSession() (*session.Session, error) {
"AWS_ACCESS_KEY",
"AWS_SECRET_KEY",
"AWS_REGION",
"AWS_REGION",
"AWS_REGION",
}
endPoint := GetEnvVariable("AWS_S3_ENDPOINT", "S3_ENDPOINT")
@@ -41,8 +39,7 @@ func CreateSession() (*session.Session, error) {
err = CheckEnvVars(awsVars)
if err != nil {
Error("Error checking environment variables\n: %s", err)
os.Exit(1)
Fatal("Error checking environment variables\n: %s", err)
}
// Configure to use MinIO Server
s3Config := &aws.Config{