Skip to content

Commit

Permalink
Fix NOTICE: s3: s3 provider "" not known - please set correctly als…
Browse files Browse the repository at this point in the history
…o in `cloudsync.credentials.verify` (#15052)
  • Loading branch information
themylogin authored Nov 27, 2024
1 parent 2628174 commit 4b20e7e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/middlewared/middlewared/rclone/remote/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ async def validate_task_basic(self, task, credentials, verrors):
task["attributes"]["region"] = response["LocationConstraint"] or "us-east-1"

async def get_credentials_extra(self, credentials):
result = {}
result = {"provider": "Other"}

if (credentials["provider"].get("endpoint") or "").rstrip("/").endswith(".scw.cloud"):
if credentials["provider"].get("max_upload_parts", 10000) == 10000:
Expand All @@ -68,7 +68,6 @@ async def get_task_extra(self, task):
server_side_encryption=task["attributes"].get("encryption") or "",
skip_region=undefined,
signatures_v2=undefined,
provider="Other",
)

if not task["credentials"]["provider"].get("skip_region", False):
Expand Down
3 changes: 1 addition & 2 deletions src/middlewared/middlewared/rclone/remote/storjix.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,14 @@ def list_buckets_sync():
return await self.middleware.run_in_thread(list_buckets_sync)

async def get_credentials_extra(self, credentials):
return {"endpoint": "https://gateway.storjshare.io"}
return {"endpoint": "https://gateway.storjshare.io", "provider": "Other"}

async def get_task_extra(self, task):
# Storj recommended these settings
return {
"chunk_size": "64M",
"disable_http2": "true",
"upload_cutoff": "64M",
"provider": "Other",
}

def get_restic_config(self, task):
Expand Down

0 comments on commit 4b20e7e

Please sign in to comment.