
Connect AWS SDK for Python (Boto3) S3 to Polycloud distributed cloud storage.
Website at https://docs.aws.amazon.com/pythonsdk.
Installation:
$ pip install boto3
Create a file named `list.py` with the following contents (substituting `mybucket`, `<your access key>`. `<your secret>` with your information):
import boto3
s3 = boto3.resource(
's3',
endpoint_url='https://polycloud.crowdapis.com',
aws_access_key_id='<your access key>',
aws_secret_access_key='<your secret>',
)
for obj in s3.Bucket('mybucket').objects.all():
print(obj.key)
Run the example:
$ python list.py