fix: restic command

This commit is contained in:
Igor Ovsyannikov
2025-09-21 15:40:00 +03:00
parent 0b05990776
commit 992829d163
+3 -1
View File
@@ -27,7 +27,9 @@ class Restic:
env["AWS_SECRET_ACCESS_KEY"] = ( env["AWS_SECRET_ACCESS_KEY"] = (
Path(masked.value).read_text().strip() Path(masked.value).read_text().strip()
) )
env["RESTIC_REPOSITORY"] = f"s3:{self.repo.url}" path = self.repo.path.lstrip("/")
url = f"{self.repo.endpoint}/{self.repo.bucket}/{path}"
env["RESTIC_REPOSITORY"] = f"s3:{url}"
case config.LocalRepository(): case config.LocalRepository():
env["RESTIC_REPOSITORY"] = self.repo.path env["RESTIC_REPOSITORY"] = self.repo.path
return env return env