rustic icon indicating copy to clipboard operation
rustic copied to clipboard

Region is needed when using custom s3 endpoint

Open kkettinger opened this issue 1 year ago • 3 comments

Currently testing out the hetzner object storage beta with this config:

[repository]
repository = "opendal:s3"
password = "XXX"

[repository.options]
access_key_id = "XXX"
secret_access_key = "XXX"
bucket = "bucket-name"
root = "/"
endpoint = "https://fsn1.your-objectstorage.com"
# region = "us-east-1"

When not using region, opendal fails:

error: backend openDAL Backend cannot be loaded: ConfigInvalid (permanent) at Builder::build, context: { service: s3 } => region is missing. Please find it by S3::detect_region() or set them in env.

When commenting out the region key, it works.

kkettinger avatar Oct 08 '24 12:10 kkettinger

Thanks for opening this issue @kkettinger

This is actually how opendal is working, see https://opendal.apache.org/docs/rust/opendal/services/struct.S3.html.

We can't fix this in rustic. If you want to have it fixed, can you please open an issue for opendal: https://github.com/apache/opendal/issues/new/choose

Thanks!

aawsome avatar Oct 10 '24 20:10 aawsome

// Set the region. This is required for some services, if you don't care about it, for example Minio service, just set it to "auto", it will be ignored.

Probably worth to keep it, and set it to 'auto', then?

simonsan avatar Oct 10 '24 22:10 simonsan

// Set the region. This is required for some services, if you don't care about it, for example Minio service, just set it to "auto", it will be ignored.

Probably worth to keep it, and set it to 'auto', then?

Setting to "auto" works!

kkettinger avatar Oct 11 '24 05:10 kkettinger

@kkettinger Can you close this issue?

sanmai-NL avatar May 30 '25 08:05 sanmai-NL