TkTech / ckanext-cloudstorage

Implements support for resource storage against multiple popular providers via apache-libcloud (S3, Azure Storage, etc...)
MIT License
35 stars 55 forks source link

S3 Driver for ca-central-1 region #46

Closed ChildOfJustice closed 3 years ago

ChildOfJustice commented 4 years ago

Good day for you! Can you tell me please, how can I correctly choose the name of the driver for the CANADA region in AWS S3. I can use many other drivers, like this for example:

(/etc/ckan/default/production.ini): ckanext.cloudstorage.driver = S3_EU_WEST

But when I'm trying to use the name "S3_CA_CENTRAL", I have this: ERROR: AttributeError: type object 'Provider' has no attribute 'S3_CA_CENTRAL'

And I cannot figurate out, from where do you use these names? There is no such in libcloud docs: https://libcloud.readthedocs.io/en/stable/_modules/libcloud/storage/drivers/s3.html?highlight=region%20s3#

Do I just need a right name of the driver? Or there is no way to use buckets from ca-central-1 region?

Thank you in advice.

TkTech commented 3 years ago

You're most likely using the master version of the project, which is still on libcloud 1.5, but you're using the documentation for version 3. Use https://libcloud.readthedocs.io/en/v1.5.0/_modules/libcloud/storage/drivers/s3.html instead. It's not too difficult to update, but someone needs to take the time to do it.

There is a libcloud2 branch, https://github.com/TkTech/ckanext-cloudstorage/tree/libcloud2, which does support S3_CA_CENTRAL.