You must have the following connection information for your object storage account readily available:
Access URL (HTTPS URL endpoint of the web service)
Access key
Secret key
This information is provided to you when your storage account is created.
Presentation
The AWS CLI (Command Line Interface) is free software (Apache 2.0 license) developed by Amazon Web Services to enable the use of AWS services through commands in a terminal (Linux shell, Windows command prompt, or macOS Terminal). This software allows managing storage as well as identities and permissions associated with them. High-level commands (simpler) help avoid the complexity of the S3 API when manipulating buckets and objects.
Simply press Enter to accept the default output format
Note: Using the EU region does not mean your data is stored outside France; Cloud Avenue data is indeed stored in mainland France.
Usage examples
In the following examples, url represents the hostname of your service endpoint accessible via HTTPS (see your connection information). The examples use “high-level” commands that hide the complexity of the S3 interface and correspond to simple use cases (managing buckets and objects).
In the example, the bucket comp1 contains three files (fic2.txt, fichier1.txt, and fichierB2.txt) and a folder (or prefix) named backup. The contents of the folder are not listed here.
In the example, the Bucket comp1 contains 4 files, one of which is inside a folder named backup. The --recursive option allows listing all objects, including traversing folders (or prefixes). The other two options may improve readability by displaying the size units of objects, the number of objects, and the total size.
In the example, the empty Bucket comp3 is deleted.
Deleting a Bucket containing at least one object :
$ aws --endpoint-url https://url s3 rb s3://comp1 remove_bucket failed: s3://comp1 An error occurred (BucketNotEmpty) when calling the DeleteBucket operation The bucket you tried to delete is not empty.
In the example, the miscellaneous folder is created if it does not already exist in the Bucket, then the local file is copied (uploaded) to the folder (or prefix).
$ aws --endpoint-url https://url s3 ls s3://comp2 –recursive
In the example, the deletion concerns the old folder; the –recursive option causes all objects present to be deleted (in this case, the Bucket is empty).