List buckets
Use the following code snippet to list buckets.
response = s3_client.list_buckets()
print('Existing buckets:')
for bucket in response['Buckets']:
print(f' {bucket["Name"]}')
This will list all buckets in Ozone volume ‘s3v’.
Use the following code snippet to list buckets.
response = s3_client.list_buckets()
print('Existing buckets:')
for bucket in response['Buckets']:
print(f' {bucket["Name"]}')
This will list all buckets in Ozone volume ‘s3v’.